Advertisement
JayPasDinspi

Testing Aimbot/Aimlock On Roblox

May 21st, 2018
28,855
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 36.76 KB | None | 0 0
  1. -- created by Moostard
  2.  
  3. local good = true
  4. for i,v in pairs(game.CoreGui:GetChildren()) do
  5. if v.Name == "Chat" and v:FindFirstChild('MainShit') then
  6. good = false
  7. end
  8. end
  9.  
  10. if good then
  11.  
  12. ---\\ GUI //---
  13.  
  14. -- Objects
  15.  
  16. local Chat = Instance.new("ScreenGui")
  17. local MainShit = Instance.new("Frame")
  18. local title = Instance.new("TextLabel")
  19. local credits = Instance.new("TextLabel")
  20. local selection = Instance.new("Frame")
  21. local head = Instance.new("ImageButton")
  22. local torso = Instance.new("ImageButton")
  23. local lefta = Instance.new("ImageButton")
  24. local righta = Instance.new("ImageButton")
  25. local leftl = Instance.new("ImageButton")
  26. local rightl = Instance.new("ImageButton")
  27. local target = Instance.new("TextLabel")
  28. local pathfind = Instance.new("TextLabel")
  29. local teamselect = Instance.new("TextLabel")
  30. local wallselect = Instance.new("TextLabel")
  31. local players = Instance.new("ScrollingFrame")
  32. local playerstxt = Instance.new("TextLabel")
  33. local teamstxt = Instance.new("TextLabel")
  34. local teams = Instance.new("ScrollingFrame")
  35. local info = Instance.new("TextLabel")
  36. local aimbot = Instance.new("TextLabel")
  37.  
  38. -- Properties
  39.  
  40. Chat.Name = "Chat"
  41. Chat.Parent = game.CoreGui
  42.  
  43. MainShit.Name = "MainShit"
  44. MainShit.Parent = Chat
  45. MainShit.Active = true
  46. MainShit.BackgroundColor3 = Color3.new(0.0784314, 0.0784314, 0.0784314)
  47. MainShit.BorderColor3 = Color3.new(0, 0, 0)
  48. MainShit.BorderSizePixel = 4
  49. MainShit.Draggable = true
  50. MainShit.Position = UDim2.new(0.699999988, 0, 0.600000024, 0)
  51. MainShit.Size = UDim2.new(0.300000012, 0, 0.400000006, 0)
  52.  
  53. title.Name = "title"
  54. title.Parent = MainShit
  55. title.BackgroundColor3 = Color3.new(0, 0, 0)
  56. title.BorderSizePixel = 0
  57. title.Size = UDim2.new(1, 0, 0.100000001, 0)
  58. title.ZIndex = 2
  59. title.Font = Enum.Font.SourceSans
  60. title.FontSize = Enum.FontSize.Size14
  61. title.Text = "Aimbot GUI"
  62. title.TextColor3 = Color3.new(1, 1, 1)
  63. title.TextScaled = true
  64. title.TextSize = 14
  65. title.TextWrapped = true
  66. title.TextXAlignment = Enum.TextXAlignment.Left
  67.  
  68. credits.Name = "credits"
  69. credits.Parent = title
  70. credits.BackgroundColor3 = Color3.new(0, 0, 0)
  71. credits.BackgroundTransparency = 1
  72. credits.BorderSizePixel = 0
  73. credits.Position = UDim2.new(0.474999994, 0, 0, 0)
  74. credits.Size = UDim2.new(0.5, 0, 1, 0)
  75. credits.ZIndex = 2
  76. credits.Font = Enum.Font.SourceSans
  77. credits.FontSize = Enum.FontSize.Size14
  78. credits.Text = "Created by Moostard"
  79. credits.TextColor3 = Color3.new(1, 1, 1)
  80. credits.TextScaled = true
  81. credits.TextSize = 14
  82. credits.TextWrapped = true
  83. credits.TextXAlignment = Enum.TextXAlignment.Right
  84.  
  85. selection.Name = "selection"
  86. selection.Parent = MainShit
  87. selection.BackgroundColor3 = Color3.new(0, 0, 0)
  88. selection.BorderSizePixel = 0
  89. selection.ClipsDescendants = true
  90. selection.Position = UDim2.new(0.699999988, 0, 0, 0)
  91. selection.Size = UDim2.new(0.300000012, 0, 0.800000012, 0)
  92.  
  93. head.Name = "head"
  94. head.Parent = selection
  95. head.BackgroundColor3 = Color3.new(0, 1, 0)
  96. head.BorderColor3 = Color3.new(0, 0, 0)
  97. head.BorderSizePixel = 0
  98. head.Position = UDim2.new(0.375, 0, 0.25, 0)
  99. head.Size = UDim2.new(0.25, 0, 0.25, 0)
  100. head.SizeConstraint = Enum.SizeConstraint.RelativeXX
  101. head.Image = "rbxassetid://328343971"
  102. head.ImageColor3 = Color3.new(1, 0, 0)
  103.  
  104. torso.Name = "torso"
  105. torso.Parent = selection
  106. torso.BackgroundColor3 = Color3.new(1, 0, 0)
  107. torso.BorderColor3 = Color3.new(0, 0, 0)
  108. torso.BorderSizePixel = 0
  109. torso.Position = UDim2.new(0.25, 0, 0.400000006, 0)
  110. torso.Size = UDim2.new(0.5, 0, 0.5, 0)
  111. torso.SizeConstraint = Enum.SizeConstraint.RelativeXX
  112. torso.Image = "rbxassetid://328343971"
  113. torso.ImageColor3 = Color3.new(1, 0, 0)
  114.  
  115. lefta.Name = "lefta"
  116. lefta.Parent = selection
  117. lefta.BackgroundColor3 = Color3.new(1, 0, 0)
  118. lefta.BorderColor3 = Color3.new(0, 0, 0)
  119. lefta.BorderSizePixel = 0
  120. lefta.Position = UDim2.new(0.00999999978, 0, 0.400000006, 0)
  121. lefta.Size = UDim2.new(0.230000004, 0, 0.5, 0)
  122. lefta.SizeConstraint = Enum.SizeConstraint.RelativeXX
  123. lefta.Image = "rbxassetid://328343971"
  124. lefta.ImageColor3 = Color3.new(1, 0, 0)
  125.  
  126. righta.Name = "righta"
  127. righta.Parent = selection
  128. righta.BackgroundColor3 = Color3.new(1, 0, 0)
  129. righta.BorderColor3 = Color3.new(0, 0, 0)
  130. righta.BorderSizePixel = 0
  131. righta.Position = UDim2.new(0.769999981, 0, 0.400000006, 0)
  132. righta.Size = UDim2.new(0.230000004, 0, 0.5, 0)
  133. righta.SizeConstraint = Enum.SizeConstraint.RelativeXX
  134. righta.Image = "rbxassetid://328343971"
  135. righta.ImageColor3 = Color3.new(1, 0, 0)
  136.  
  137. leftl.Name = "leftl"
  138. leftl.Parent = selection
  139. leftl.BackgroundColor3 = Color3.new(1, 0, 0)
  140. leftl.BorderColor3 = Color3.new(0, 0, 0)
  141. leftl.BorderSizePixel = 0
  142. leftl.Position = UDim2.new(0.25, 0, 0.694999993, 0)
  143. leftl.Size = UDim2.new(0.230000004, 0, 0.5, 0)
  144. leftl.SizeConstraint = Enum.SizeConstraint.RelativeXX
  145. leftl.Image = "rbxassetid://328343971"
  146. leftl.ImageColor3 = Color3.new(1, 0, 0)
  147.  
  148. rightl.Name = "rightl"
  149. rightl.Parent = selection
  150. rightl.BackgroundColor3 = Color3.new(1, 0, 0)
  151. rightl.BorderColor3 = Color3.new(0, 0, 0)
  152. rightl.BorderSizePixel = 0
  153. rightl.Position = UDim2.new(0.524999976, 0, 0.694999993, 0)
  154. rightl.Size = UDim2.new(0.230000004, 0, 0.5, 0)
  155. rightl.SizeConstraint = Enum.SizeConstraint.RelativeXX
  156. rightl.Image = "rbxassetid://328343971"
  157. rightl.ImageColor3 = Color3.new(1, 0, 0)
  158.  
  159. target.Name = "target"
  160. target.Parent = selection
  161. target.BackgroundColor3 = Color3.new(1, 1, 1)
  162. target.BackgroundTransparency = 1
  163. target.BorderSizePixel = 0
  164. target.Position = UDim2.new(0, 0, 0.140000001, 0)
  165. target.Size = UDim2.new(1, 0, 0.100000001, 0)
  166. target.Font = Enum.Font.SourceSans
  167. target.FontSize = Enum.FontSize.Size14
  168. target.Text = "Target"
  169. target.TextColor3 = Color3.new(1, 1, 1)
  170. target.TextScaled = true
  171. target.TextSize = 14
  172. target.TextWrapped = true
  173.  
  174. pathfind.Name = "pathfind"
  175. pathfind.Parent = MainShit
  176. pathfind.BackgroundColor3 = Color3.new(1, 1, 1)
  177. pathfind.BackgroundTransparency = 1
  178. pathfind.BorderSizePixel = 0
  179. pathfind.Position = UDim2.new(0.5, 0, 0.800000012, 0)
  180. pathfind.Size = UDim2.new(0.25, 0, 0.200000003, 0)
  181. pathfind.Font = Enum.Font.SourceSans
  182. pathfind.FontSize = Enum.FontSize.Size14
  183. pathfind.Text = "Press R to toggle pathfinding on."
  184. pathfind.TextColor3 = Color3.new(1, 1, 1)
  185. pathfind.TextScaled = true
  186. pathfind.TextSize = 14
  187. pathfind.TextWrapped = true
  188.  
  189. teamselect.Name = "teamselect"
  190. teamselect.Parent = MainShit
  191. teamselect.BackgroundColor3 = Color3.new(1, 1, 1)
  192. teamselect.BackgroundTransparency = 1
  193. teamselect.BorderSizePixel = 0
  194. teamselect.Position = UDim2.new(0.25, 0, 0.800000012, 0)
  195. teamselect.Size = UDim2.new(0.25, 0, 0.200000003, 0)
  196. teamselect.Font = Enum.Font.SourceSans
  197. teamselect.FontSize = Enum.FontSize.Size14
  198. teamselect.Text = "Press Q to toggle teamkill on."
  199. teamselect.TextColor3 = Color3.new(1, 1, 1)
  200. teamselect.TextScaled = true
  201. teamselect.TextSize = 14
  202. teamselect.TextWrapped = true
  203.  
  204. wallselect.Name = "wallselect"
  205. wallselect.Parent = MainShit
  206. wallselect.BackgroundColor3 = Color3.new(1, 1, 1)
  207. wallselect.BackgroundTransparency = 1
  208. wallselect.BorderSizePixel = 0
  209. wallselect.Position = UDim2.new(0.75, 0, 0.800000012, 0)
  210. wallselect.Size = UDim2.new(0.25, 0, 0.200000003, 0)
  211. wallselect.Font = Enum.Font.SourceSans
  212. wallselect.FontSize = Enum.FontSize.Size14
  213. wallselect.Text = "Press T to toggle aiming through walls off."
  214. wallselect.TextColor3 = Color3.new(1, 1, 1)
  215. wallselect.TextScaled = true
  216. wallselect.TextSize = 14
  217. wallselect.TextWrapped = true
  218.  
  219. players.Name = "players"
  220. players.Parent = MainShit
  221. players.BackgroundColor3 = Color3.new(0, 0, 0)
  222. players.BorderSizePixel = 0
  223. players.Position = UDim2.new(0.00999999978, 0, 0.200000003, 0)
  224. players.Size = UDim2.new(0.300000012, 0, 0.5, 0)
  225. players.BottomImage = "rbxasset://textures/ui/Scroll/scroll-middle.png"
  226. players.CanvasSize = UDim2.new(0, 0, 0, 0)
  227. players.ScrollBarThickness = 5
  228. players.TopImage = "rbxasset://textures/ui/Scroll/scroll-middle.png"
  229.  
  230. playerstxt.Name = "playerstxt"
  231. playerstxt.Parent = MainShit
  232. playerstxt.BackgroundColor3 = Color3.new(1, 1, 1)
  233. playerstxt.BackgroundTransparency = 1
  234. playerstxt.BorderSizePixel = 0
  235. playerstxt.Position = UDim2.new(0.00999999978, 0, 0.100000001, 0)
  236. playerstxt.Size = UDim2.new(0.300000012, 0, 0.100000001, 0)
  237. playerstxt.Font = Enum.Font.SourceSans
  238. playerstxt.FontSize = Enum.FontSize.Size14
  239. playerstxt.Text = "Player Whitelists"
  240. playerstxt.TextColor3 = Color3.new(1, 1, 1)
  241. playerstxt.TextScaled = true
  242. playerstxt.TextSize = 14
  243. playerstxt.TextWrapped = true
  244.  
  245. teamstxt.Name = "teamstxt"
  246. teamstxt.Parent = MainShit
  247. teamstxt.BackgroundColor3 = Color3.new(1, 1, 1)
  248. teamstxt.BackgroundTransparency = 1
  249. teamstxt.BorderSizePixel = 0
  250. teamstxt.Position = UDim2.new(0.351000011, 0, 0.100000001, 0)
  251. teamstxt.Size = UDim2.new(0.300000012, 0, 0.100000001, 0)
  252. teamstxt.Font = Enum.Font.SourceSans
  253. teamstxt.FontSize = Enum.FontSize.Size14
  254. teamstxt.Text = "Team Whitelists"
  255. teamstxt.TextColor3 = Color3.new(1, 1, 1)
  256. teamstxt.TextScaled = true
  257. teamstxt.TextSize = 14
  258. teamstxt.TextWrapped = true
  259.  
  260. teams.Name = "teams"
  261. teams.Parent = MainShit
  262. teams.BackgroundColor3 = Color3.new(0, 0, 0)
  263. teams.BorderSizePixel = 0
  264. teams.Position = UDim2.new(0.351000011, 0, 0.200000003, 0)
  265. teams.Size = UDim2.new(0.300000012, 0, 0.5, 0)
  266. teams.BottomImage = "rbxasset://textures/ui/Scroll/scroll-middle.png"
  267. teams.CanvasSize = UDim2.new(0, 0, 0, 0)
  268. teams.ScrollBarThickness = 5
  269. teams.TopImage = "rbxasset://textures/ui/Scroll/scroll-middle.png"
  270.  
  271. info.Name = "info"
  272. info.Parent = MainShit
  273. info.BackgroundColor3 = Color3.new(1, 1, 1)
  274. info.BackgroundTransparency = 1
  275. info.BorderSizePixel = 0
  276. info.Position = UDim2.new(0, 0, 0.699999988, 0)
  277. info.Size = UDim2.new(0.699999988, 0, 0.100000001, 0)
  278. info.Font = Enum.Font.SourceSans
  279. info.FontSize = Enum.FontSize.Size14
  280. info.Text = "Press \"L\" to toggle the hotkey changing GUI, and \"P\" to toggle the aimbot GUI."
  281. info.TextColor3 = Color3.new(1, 1, 1)
  282. info.TextScaled = true
  283. info.TextSize = 14
  284. info.TextWrapped = true
  285.  
  286. aimbot.Name = "aimbot"
  287. aimbot.Parent = MainShit
  288. aimbot.BackgroundColor3 = Color3.new(1, 1, 1)
  289. aimbot.BackgroundTransparency = 1
  290. aimbot.BorderSizePixel = 0
  291. aimbot.Position = UDim2.new(0, 0, 0.800000012, 0)
  292. aimbot.Size = UDim2.new(0.25, 0, 0.200000003, 0)
  293. aimbot.Font = Enum.Font.SourceSans
  294. aimbot.FontSize = Enum.FontSize.Size14
  295. aimbot.Text = "Press E to toggle aimbot on."
  296. aimbot.TextColor3 = Color3.new(1, 1, 1)
  297. aimbot.TextScaled = true
  298. aimbot.TextSize = 14
  299. aimbot.TextWrapped = true
  300.  
  301. -- Objects
  302.  
  303. local ScreenGui = Instance.new("ScreenGui")
  304. local Frame = Instance.new("Frame")
  305. local title = Instance.new("TextLabel")
  306. local credits = Instance.new("TextLabel")
  307. local ChangeAim = Instance.new("TextButton")
  308. local ChangeAimLabel = Instance.new("TextLabel")
  309. local ChangeTeamLabel = Instance.new("TextLabel")
  310. local ChangeTeam = Instance.new("TextButton")
  311. local ChangePathLabel = Instance.new("TextLabel")
  312. local ChangePath = Instance.new("TextButton")
  313. local ChangeWallLabel = Instance.new("TextLabel")
  314. local ChangeWall = Instance.new("TextButton")
  315. local ChangeHoldLabel = Instance.new("TextLabel")
  316. local ChangeToggle = Instance.new("TextButton")
  317. local ChangeSelection = Instance.new("TextButton")
  318. local ChangeSelectionLabel = Instance.new("TextLabel")
  319.  
  320. -- Properties
  321.  
  322. ScreenGui.Parent = game.CoreGui
  323. ScreenGui.Enabled = false
  324.  
  325. Frame.Parent = ScreenGui
  326. Frame.AnchorPoint = Vector2.new(0.5, 0.5)
  327. Frame.BackgroundColor3 = Color3.new(0.0784314, 0.0784314, 0.0784314)
  328. Frame.BorderColor3 = Color3.new(0, 0, 0)
  329. Frame.BorderSizePixel = 5
  330. Frame.Position = UDim2.new(0.5, 0, 0.5, 0)
  331. Frame.Size = UDim2.new(0.5, 0, 0.5, 0)
  332.  
  333. title.Name = "title"
  334. title.Parent = Frame
  335. title.BackgroundColor3 = Color3.new(0, 0, 0)
  336. title.BorderSizePixel = 0
  337. title.Size = UDim2.new(1, 0, 0.100000001, 0)
  338. title.ZIndex = 2
  339. title.Font = Enum.Font.SourceSans
  340. title.FontSize = Enum.FontSize.Size14
  341. title.Text = "Aimbot Hotkey Change GUI"
  342. title.TextColor3 = Color3.new(1, 1, 1)
  343. title.TextScaled = true
  344. title.TextSize = 14
  345. title.TextWrapped = true
  346. title.TextXAlignment = Enum.TextXAlignment.Left
  347.  
  348. credits.Name = "credits"
  349. credits.Parent = title
  350. credits.BackgroundColor3 = Color3.new(0, 0, 0)
  351. credits.BackgroundTransparency = 1
  352. credits.BorderSizePixel = 0
  353. credits.Position = UDim2.new(0.474999994, 0, 0, 0)
  354. credits.Size = UDim2.new(0.5, 0, 1, 0)
  355. credits.ZIndex = 2
  356. credits.Font = Enum.Font.SourceSans
  357. credits.FontSize = Enum.FontSize.Size14
  358. credits.Text = "Created by Moostard"
  359. credits.TextColor3 = Color3.new(1, 1, 1)
  360. credits.TextScaled = true
  361. credits.TextSize = 14
  362. credits.TextWrapped = true
  363. credits.TextXAlignment = Enum.TextXAlignment.Right
  364.  
  365. ChangeAim.Name = "ChangeAim"
  366. ChangeAim.Parent = Frame
  367. ChangeAim.BackgroundColor3 = Color3.new(0, 0, 0)
  368. ChangeAim.BorderSizePixel = 0
  369. ChangeAim.Position = UDim2.new(0.150000006, 0, 0.25, 0)
  370. ChangeAim.Size = UDim2.new(0.200000003, 0, 0.150000006, 0)
  371. ChangeAim.Font = Enum.Font.SourceSans
  372. ChangeAim.FontSize = Enum.FontSize.Size14
  373. ChangeAim.Text = "Current: E"
  374. ChangeAim.TextColor3 = Color3.new(1, 1, 1)
  375. ChangeAim.TextScaled = true
  376. ChangeAim.TextSize = 14
  377. ChangeAim.TextWrapped = true
  378.  
  379. ChangeAimLabel.Name = "ChangeAimLabel"
  380. ChangeAimLabel.Parent = Frame
  381. ChangeAimLabel.BackgroundColor3 = Color3.new(1, 1, 1)
  382. ChangeAimLabel.BackgroundTransparency = 1
  383. ChangeAimLabel.Position = UDim2.new(0, 0, 0.125, 0)
  384. ChangeAimLabel.Size = UDim2.new(0.5, 0, 0.100000001, 0)
  385. ChangeAimLabel.Font = Enum.Font.SourceSans
  386. ChangeAimLabel.FontSize = Enum.FontSize.Size14
  387. ChangeAimLabel.Text = "Change the Aimbot Hotkey"
  388. ChangeAimLabel.TextColor3 = Color3.new(1, 1, 1)
  389. ChangeAimLabel.TextScaled = true
  390. ChangeAimLabel.TextSize = 14
  391. ChangeAimLabel.TextWrapped = true
  392.  
  393. ChangeTeamLabel.Name = "ChangeTeamLabel"
  394. ChangeTeamLabel.Parent = Frame
  395. ChangeTeamLabel.BackgroundColor3 = Color3.new(1, 1, 1)
  396. ChangeTeamLabel.BackgroundTransparency = 1
  397. ChangeTeamLabel.Position = UDim2.new(0, 0, 0.425000012, 0)
  398. ChangeTeamLabel.Size = UDim2.new(0.5, 0, 0.100000001, 0)
  399. ChangeTeamLabel.Font = Enum.Font.SourceSans
  400. ChangeTeamLabel.FontSize = Enum.FontSize.Size14
  401. ChangeTeamLabel.Text = "Change the Teamkill Hotkey"
  402. ChangeTeamLabel.TextColor3 = Color3.new(1, 1, 1)
  403. ChangeTeamLabel.TextScaled = true
  404. ChangeTeamLabel.TextSize = 14
  405. ChangeTeamLabel.TextWrapped = true
  406.  
  407. ChangeTeam.Name = "ChangeTeam"
  408. ChangeTeam.Parent = Frame
  409. ChangeTeam.BackgroundColor3 = Color3.new(0, 0, 0)
  410. ChangeTeam.BorderSizePixel = 0
  411. ChangeTeam.Position = UDim2.new(0.150000006, 0, 0.550000012, 0)
  412. ChangeTeam.Size = UDim2.new(0.200000003, 0, 0.150000006, 0)
  413. ChangeTeam.Font = Enum.Font.SourceSans
  414. ChangeTeam.FontSize = Enum.FontSize.Size14
  415. ChangeTeam.Text = "Current: Q"
  416. ChangeTeam.TextColor3 = Color3.new(1, 1, 1)
  417. ChangeTeam.TextScaled = true
  418. ChangeTeam.TextSize = 14
  419. ChangeTeam.TextWrapped = true
  420.  
  421. ChangePathLabel.Name = "ChangePathLabel"
  422. ChangePathLabel.Parent = Frame
  423. ChangePathLabel.BackgroundColor3 = Color3.new(1, 1, 1)
  424. ChangePathLabel.BackgroundTransparency = 1
  425. ChangePathLabel.Position = UDim2.new(0, 0, 0.725000024, 0)
  426. ChangePathLabel.Size = UDim2.new(0.5, 0, 0.100000001, 0)
  427. ChangePathLabel.Font = Enum.Font.SourceSans
  428. ChangePathLabel.FontSize = Enum.FontSize.Size14
  429. ChangePathLabel.Text = "Change the Pathfinding Hotkey"
  430. ChangePathLabel.TextColor3 = Color3.new(1, 1, 1)
  431. ChangePathLabel.TextScaled = true
  432. ChangePathLabel.TextSize = 14
  433. ChangePathLabel.TextWrapped = true
  434.  
  435. ChangePath.Name = "ChangePath"
  436. ChangePath.Parent = Frame
  437. ChangePath.BackgroundColor3 = Color3.new(0, 0, 0)
  438. ChangePath.BorderSizePixel = 0
  439. ChangePath.Position = UDim2.new(0.150000006, 0, 0.850000024, 0)
  440. ChangePath.Size = UDim2.new(0.200000003, 0, 0.150000006, 0)
  441. ChangePath.Font = Enum.Font.SourceSans
  442. ChangePath.FontSize = Enum.FontSize.Size14
  443. ChangePath.Text = "Current: R"
  444. ChangePath.TextColor3 = Color3.new(1, 1, 1)
  445. ChangePath.TextScaled = true
  446. ChangePath.TextSize = 14
  447. ChangePath.TextWrapped = true
  448.  
  449. ChangeWallLabel.Name = "ChangeWallLabel"
  450. ChangeWallLabel.Parent = Frame
  451. ChangeWallLabel.BackgroundColor3 = Color3.new(1, 1, 1)
  452. ChangeWallLabel.BackgroundTransparency = 1
  453. ChangeWallLabel.Position = UDim2.new(0.5, 0, 0.125, 0)
  454. ChangeWallLabel.Size = UDim2.new(0.5, 0, 0.100000001, 0)
  455. ChangeWallLabel.Font = Enum.Font.SourceSans
  456. ChangeWallLabel.FontSize = Enum.FontSize.Size14
  457. ChangeWallLabel.Text = "Change the Aiming Through Walls Hotkey"
  458. ChangeWallLabel.TextColor3 = Color3.new(1, 1, 1)
  459. ChangeWallLabel.TextScaled = true
  460. ChangeWallLabel.TextSize = 14
  461. ChangeWallLabel.TextWrapped = true
  462.  
  463. ChangeWall.Name = "ChangeWall"
  464. ChangeWall.Parent = Frame
  465. ChangeWall.BackgroundColor3 = Color3.new(0, 0, 0)
  466. ChangeWall.BorderSizePixel = 0
  467. ChangeWall.Position = UDim2.new(0.649999976, 0, 0.25, 0)
  468. ChangeWall.Size = UDim2.new(0.200000003, 0, 0.150000006, 0)
  469. ChangeWall.Font = Enum.Font.SourceSans
  470. ChangeWall.FontSize = Enum.FontSize.Size14
  471. ChangeWall.Text = "Current: T"
  472. ChangeWall.TextColor3 = Color3.new(1, 1, 1)
  473. ChangeWall.TextScaled = true
  474. ChangeWall.TextSize = 14
  475. ChangeWall.TextWrapped = true
  476.  
  477. ChangeHoldLabel.Name = "ChangeHoldLabel"
  478. ChangeHoldLabel.Parent = Frame
  479. ChangeHoldLabel.BackgroundColor3 = Color3.new(1, 1, 1)
  480. ChangeHoldLabel.BackgroundTransparency = 1
  481. ChangeHoldLabel.Position = UDim2.new(0.5, 0, 0.425000012, 0)
  482. ChangeHoldLabel.Size = UDim2.new(0.5, 0, 0.100000001, 0)
  483. ChangeHoldLabel.Font = Enum.Font.SourceSans
  484. ChangeHoldLabel.FontSize = Enum.FontSize.Size14
  485. ChangeHoldLabel.Text = "Change toggling/holding keys to enable."
  486. ChangeHoldLabel.TextColor3 = Color3.new(1, 1, 1)
  487. ChangeHoldLabel.TextScaled = true
  488. ChangeHoldLabel.TextSize = 14
  489. ChangeHoldLabel.TextWrapped = true
  490.  
  491. ChangeToggle.Name = "ChangeToggle"
  492. ChangeToggle.Parent = Frame
  493. ChangeToggle.BackgroundColor3 = Color3.new(0, 0, 0)
  494. ChangeToggle.BorderSizePixel = 0
  495. ChangeToggle.Position = UDim2.new(0.550000012, 0, 0.550000012, 0)
  496. ChangeToggle.Size = UDim2.new(0.400000006, 0, 0.150000006, 0)
  497. ChangeToggle.Font = Enum.Font.SourceSans
  498. ChangeToggle.FontSize = Enum.FontSize.Size14
  499. ChangeToggle.Text = "Current: Toggling"
  500. ChangeToggle.TextColor3 = Color3.new(1, 1, 1)
  501. ChangeToggle.TextScaled = true
  502. ChangeToggle.TextSize = 14
  503. ChangeToggle.TextWrapped = true
  504.  
  505. ChangeSelection.Name = "ChangeSelection"
  506. ChangeSelection.Parent = Frame
  507. ChangeSelection.BackgroundColor3 = Color3.new(0, 0, 0)
  508. ChangeSelection.BorderSizePixel = 0
  509. ChangeSelection.Position = UDim2.new(0.550000012, 0, 0.850000024, 0)
  510. ChangeSelection.Size = UDim2.new(0.400000006, 0, 0.150000006, 0)
  511. ChangeSelection.Font = Enum.Font.SourceSans
  512. ChangeSelection.FontSize = Enum.FontSize.Size14
  513. ChangeSelection.Text = "Current: Closest To Player"
  514. ChangeSelection.TextColor3 = Color3.new(1, 1, 1)
  515. ChangeSelection.TextScaled = true
  516. ChangeSelection.TextSize = 14
  517. ChangeSelection.TextWrapped = true
  518.  
  519. ChangeSelectionLabel.Name = "ChangeSelectionLabel"
  520. ChangeSelectionLabel.Parent = Frame
  521. ChangeSelectionLabel.BackgroundColor3 = Color3.new(1, 1, 1)
  522. ChangeSelectionLabel.BackgroundTransparency = 1
  523. ChangeSelectionLabel.Position = UDim2.new(0.5, 0, 0.725000024, 0)
  524. ChangeSelectionLabel.Size = UDim2.new(0.5, 0, 0.100000001, 0)
  525. ChangeSelectionLabel.Font = Enum.Font.SourceSans
  526. ChangeSelectionLabel.FontSize = Enum.FontSize.Size14
  527. ChangeSelectionLabel.Text = "Change selection mode."
  528. ChangeSelectionLabel.TextColor3 = Color3.new(1, 1, 1)
  529. ChangeSelectionLabel.TextScaled = true
  530. ChangeSelectionLabel.TextSize = 14
  531. ChangeSelectionLabel.TextWrapped = true
  532.  
  533. ---\\ SCRIPT //---
  534.  
  535. local plr = game.Players.LocalPlayer
  536. local haaa = false
  537. local mou = plr:GetMouse()
  538. local aimkey = "e"
  539. local toggle = true
  540. local teamkey = "q"
  541. local pathkey = "r"
  542. local wallkey = "t"
  543. local tk = false
  544. local path = false
  545. local nearmouse = false
  546. local pastpath = nil
  547. local editing = nil
  548. local walls = true
  549. local plrs = {}
  550. local tms = {}
  551.  
  552. function distance(point1,point2,heck)
  553. local result = math.huge
  554. if nearmouse == false and (heck == false or heck == nil) then
  555. result = (point1-point2).magnitude
  556. else
  557. local hmm,eh = workspace.CurrentCamera:WorldToViewportPoint(point2)
  558. print((workspace.CurrentCamera.ViewportSize-Vector2.new(0,hmm.X,0,hmm.Y)).magnitude)
  559. return (workspace.CurrentCamera.ViewportSize-Vector2.new(0,hmm.X,0,hmm.Y)).magnitude
  560. end
  561. print(result)
  562. return result
  563. end
  564.  
  565. ChangeToggle.MouseButton1Click:connect(function()
  566. if toggle == true then
  567. toggle = false
  568. ChangeToggle.Text = "Current: Holding"
  569. else
  570. toggle = true
  571. ChangeToggle.Text = "Current: Toggling"
  572. end
  573. end)
  574. ChangeSelection.MouseButton1Click:connect(function()
  575. if nearmouse == true then
  576. nearmouse = false
  577. ChangeSelection.Text = "Current: Closest To Player"
  578. else
  579. nearmouse = true
  580. ChangeSelection.Text = "Current: Closest To Center of Camera"
  581. end
  582. end)
  583. ChangeAim.MouseButton1Click:connect(function()
  584. if editing == nil then
  585. ChangeAim.Text = "Press any key to change."
  586. editing = "aim"
  587. end
  588. end)
  589. ChangeWall.MouseButton1Click:connect(function()
  590. if editing == nil then
  591. ChangeWall.Text = "Press any key to change."
  592. editing = "wall"
  593. end
  594. end)
  595. ChangePath.MouseButton1Click:connect(function()
  596. if editing == nil then
  597. ChangePath.Text = "Press any key to change."
  598. editing = "path"
  599. end
  600. end)
  601. ChangeTeam.MouseButton1Click:connect(function()
  602. if editing == nil then
  603. ChangeTeam.Text = "Press any key to change."
  604. editing = "team"
  605. end
  606. end)
  607.  
  608. function cansee(targ)
  609. local cam = workspace.CurrentCamera
  610. local ray = Ray.new(plr.Character.Head.CFrame.p, (targ.CFrame.p - plr.Character.Head.CFrame.p).unit * 300)
  611. local part, position = workspace:FindPartOnRayWithIgnoreList(ray, {plr.Character}, false, true)
  612. if part then
  613. local humanoid = part.Parent:FindFirstChildOfClass("Humanoid")
  614.  
  615. if not humanoid then
  616. humanoid = part.Parent.Parent:FindFirstChildOfClass("Humanoid")
  617. end
  618.  
  619. if humanoid and targ and humanoid.Parent == targ.Parent then
  620. local blah,actualthing = cam:WorldToScreenPoint(targ.Position)
  621. if actualthing == true then
  622. return true
  623. else
  624. return false
  625. end
  626. else
  627. return false
  628. end
  629. else
  630. return false
  631. end
  632. end
  633.  
  634. function getdatray(pointuno,pointdos)
  635. local ray = Ray.new(pointdos,(pointdos - pointuno).unit * 300)
  636. local distance = (pointuno - pointdos).magnitude
  637. local pos = CFrame.new(pointuno, pointdos) * CFrame.new(0, 0, -distance / 2)
  638. return distance,pos
  639. end
  640.  
  641. mou.Button2Down:connect(function()
  642. if editing ~= nil then
  643. if editing == "aim" then
  644. aimkey = "RMB"
  645. if haaa then
  646. aimbot.Text = "Press RMB to toggle aimbot off."
  647. else
  648. aimbot.Text = "Press RMB to toggle aimbot on."
  649. end
  650. ChangeAim.Text = "Current: RMB"
  651. elseif editing == "team" then
  652. teamkey = "RMB"
  653. if tk then
  654. teamselect.Text = "Press RMB to toggle teamkill off."
  655. else
  656. teamselect.Text = "Press RMB to toggle teamkill on."
  657. end
  658. ChangeTeam.Text = "Current: RMB"
  659. elseif editing == "path" then
  660. pathkey = "RMB"
  661. if path then
  662. pathfind.Text = "Press RMB to toggle pathfinding off."
  663. else
  664. pathfind.Text = "Press RMB to toggle pathfinding on."
  665. end
  666. ChangePath.Text = "Current: RMB"
  667. elseif editing == "wall" then
  668. wallkey = "RMB"
  669. if walls then
  670. wallselect.Text = "Press RMB to toggle aiming through walls off."
  671. else
  672. wallselect.Text = "Press RMB to toggle aiming through walls on."
  673. end
  674. ChangeWall.Text = "Current: RMB"
  675. end
  676. editing = nil
  677. else
  678. if aimkey == "RMB" then
  679. if haaa and toggle == true then
  680. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot on."
  681. haaa = false
  682. elseif haaa == false then
  683. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot off."
  684. haaa = true
  685. end
  686. elseif teamkey == "RMB" then
  687. if tk then
  688. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill on."
  689. tk = false
  690. else
  691. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill off."
  692. tk = true
  693. end
  694. elseif pathkey == "RMB" then
  695. if path then
  696. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding on."
  697. path = false
  698. else
  699. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding off."
  700. path = true
  701. end
  702. elseif wallkey == "RMB" then
  703. if walls then
  704. walls = false
  705. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls on."
  706. else
  707. walls = true
  708. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls off."
  709. end
  710. end
  711. end
  712. end)
  713.  
  714. mou.Button2Up:connect(function()
  715. if aimkey == "RMB" and toggle == false then
  716. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot on."
  717. haaa = false
  718. end
  719. end)
  720.  
  721. mou.KeyDown:connect(function(key)
  722. if editing ~= nil then
  723. if editing == "aim" then
  724. aimkey = key
  725. if haaa then
  726. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot off."
  727. else
  728. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot on."
  729. end
  730. ChangeAim.Text = "Current: "..string.upper(key)
  731. elseif editing == "team" then
  732. teamkey = key
  733. if tk then
  734. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill off."
  735. else
  736. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill on."
  737. end
  738. ChangeTeam.Text = "Current: "..string.upper(key)
  739. elseif editing == "path" then
  740. pathkey = key
  741. if path then
  742. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding off."
  743. else
  744. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding on."
  745. end
  746. ChangePath.Text = "Current: "..string.upper(key)
  747. elseif editing == "wall" then
  748. wallkey = key
  749. if walls then
  750. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls off."
  751. else
  752. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls on."
  753. end
  754. ChangeWall.Text = "Current: "..string.upper(key)
  755. end
  756. editing = nil
  757. elseif key == "p" then
  758. Chat.Enabled = not Chat.Enabled
  759. elseif key == "l" then
  760. ScreenGui.Enabled = not ScreenGui.Enabled
  761. elseif key == teamkey then
  762. if tk then
  763. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill on."
  764. tk = false
  765. else
  766. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill off."
  767. tk = true
  768. end
  769. elseif key == aimkey then
  770. if haaa and toggle == true then
  771. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot on."
  772. haaa = false
  773. elseif haaa == false then
  774. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot off."
  775. haaa = true
  776. end
  777. elseif key == pathkey then
  778. if path then
  779. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding on."
  780. path = false
  781. else
  782. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding off."
  783. path = true
  784. end
  785. elseif key == wallkey then
  786. if walls then
  787. walls = false
  788. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls on."
  789. else
  790. walls = true
  791. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls off."
  792. end
  793. end
  794. end)
  795.  
  796. mou.KeyUp:connect(function(key)
  797. if key == aimkey and toggle == false then
  798. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot on."
  799. haaa = false
  800. end
  801. end)
  802.  
  803. local thatthing = nil
  804. local Camera = game.Workspace.CurrentCamera
  805. local bestdist = nil
  806. local setpart = "Head"
  807. local selectedpart = "Head"
  808. local canseenearest = false
  809.  
  810. head.MouseButton1Click:connect(function()
  811. righta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  812. lefta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  813. rightl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  814. leftl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  815. torso.BackgroundColor3 = Color3.fromRGB(255,0,0)
  816. head.BackgroundColor3 = Color3.fromRGB(0,255,0)
  817. setpart = "Head"
  818. end)
  819. torso.MouseButton1Click:connect(function()
  820. righta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  821. lefta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  822. rightl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  823. leftl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  824. torso.BackgroundColor3 = Color3.fromRGB(0,255,0)
  825. head.BackgroundColor3 = Color3.fromRGB(255,0,0)
  826. setpart = "Torso"
  827. end)
  828. righta.MouseButton1Click:connect(function()
  829. righta.BackgroundColor3 = Color3.fromRGB(0,255,0)
  830. lefta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  831. rightl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  832. leftl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  833. torso.BackgroundColor3 = Color3.fromRGB(255,0,0)
  834. head.BackgroundColor3 = Color3.fromRGB(255,0,0)
  835. setpart = "Right Arm"
  836. end)
  837. lefta.MouseButton1Click:connect(function()
  838. righta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  839. lefta.BackgroundColor3 = Color3.fromRGB(0,255,0)
  840. rightl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  841. leftl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  842. torso.BackgroundColor3 = Color3.fromRGB(255,0,0)
  843. head.BackgroundColor3 = Color3.fromRGB(255,0,0)
  844. setpart = "Left Arm"
  845. end)
  846. rightl.MouseButton1Click:connect(function()
  847. righta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  848. lefta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  849. rightl.BackgroundColor3 = Color3.fromRGB(0,255,0)
  850. leftl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  851. torso.BackgroundColor3 = Color3.fromRGB(255,0,0)
  852. head.BackgroundColor3 = Color3.fromRGB(255,0,0)
  853. setpart = "Right Leg"
  854. end)
  855. leftl.MouseButton1Click:connect(function()
  856. righta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  857. lefta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  858. rightl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  859. leftl.BackgroundColor3 = Color3.fromRGB(0,255,0)
  860. torso.BackgroundColor3 = Color3.fromRGB(255,0,0)
  861. head.BackgroundColor3 = Color3.fromRGB(255,0,0)
  862. setpart = "Left Leg"
  863. end)
  864. local recentlyded = 0
  865. local lasttarg = nil
  866. game:GetService('RunService').Stepped:connect(function(time,thing)
  867. thatthing = nil
  868. canseenearest = false
  869. selectedpart = setpart
  870. Camera = game.Workspace.CurrentCamera
  871. bestdist = nil
  872. if haaa or path then
  873. if walls == false then
  874. canseenearest = true
  875. end
  876. for i,v in pairs(game.Players:GetChildren()) do
  877. if v ~= game.Players.LocalPlayer and v.Character and v.Character:FindFirstChild('Head') and v.Character:FindFirstChildOfClass('Humanoid') and v.Character:FindFirstChildOfClass('Humanoid').Health > 0 then
  878. if tk == false and (v.Team ~= game.Players.LocalPlayer.Team or game.Players.LocalPlayer.Team == nil) then
  879. if bestdist == nil or distance(game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p) < bestdist or (canseenearest == false and cansee(v.Character.Head)) then
  880. local gudguy = false
  881. for a,c in pairs(tms) do
  882. if v.Team == c then
  883. gudguy = true
  884. end
  885. end
  886. for a,c in pairs(plrs) do
  887. if v == c then
  888. gudguy = true
  889. end
  890. end
  891. if gudguy == false then
  892. if canseenearest == true and cansee(v.Character.Head) then
  893. thatthing = v
  894. bestdist = distance(game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p)
  895. elseif canseenearest == false then
  896. if cansee(v.Character.Head) then
  897. canseenearest = true
  898. end
  899. thatthing = v
  900. bestdist = distance(game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p)
  901. end
  902. end
  903. end
  904. elseif tk == true then
  905. if bestdist == nil or distance(game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p) < bestdist or (canseenearest == false and cansee(v.Character.Head)) and (v.Team ~= game.Players.LocalPlayer.Team or game.Players.LocalPlayer.Team == nil) then
  906. local gudguy = false
  907. for a,c in pairs(plrs) do
  908. if v == c then
  909. gudguy = true
  910. end
  911. end
  912. for a,c in pairs(tms) do
  913. if v.Team == c then
  914. gudguy = true
  915. end
  916. end
  917. if gudguy == false then
  918. if canseenearest == true and cansee(v.Character.Head) then
  919. thatthing = v
  920. bestdist = distance(game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p)
  921. elseif canseenearest == false then
  922. if cansee(v.Character.Head) then
  923. canseenearest = true
  924. end
  925. thatthing = v
  926. bestdist = distance(game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p)
  927. end
  928. end
  929. end
  930. end
  931. end
  932. end
  933. if thatthing ~= nil and bestdist ~= nil and plr.Character:FindFirstChild('HumanoidRootPart') and thatthing.Character:FindFirstChild('HumanoidRootPart') then
  934. if haaa then
  935. if selectedpart == "Right Arm" then
  936. if thatthing.Character:FindFirstChild('Right Arm') == nil then
  937. if thatthing.Character:FindFirstChild('RightLowerArm') then
  938. selectedpart = "RightLowerArm"
  939. else
  940. selectedpart = "Head"
  941. end
  942. end
  943. elseif selectedpart == "Left Arm" then
  944. if thatthing.Character:FindFirstChild('Left Arm') == nil then
  945. if thatthing.Character:FindFirstChild('LeftLowerArm') then
  946. selectedpart = "LeftLowerArm"
  947. else
  948. selectedpart = "Head"
  949. end
  950. end
  951. elseif selectedpart == "Left Leg" then
  952. if thatthing.Character:FindFirstChild('Left Leg') == nil then
  953. if thatthing.Character:FindFirstChild('LeftLowerLeg') then
  954. selectedpart = "LeftLowerLeg"
  955. else
  956. selectedpart = "Head"
  957. end
  958. end
  959. elseif selectedpart == "Right Leg" then
  960. if thatthing.Character:FindFirstChild('Right Leg') == nil then
  961. if thatthing.Character:FindFirstChild('RightLowerLeg') then
  962. selectedpart = "RightLowerLeg"
  963. else
  964. selectedpart = "Head"
  965. end
  966. end
  967. elseif selectedpart == "Torso" then
  968. if thatthing.Character:FindFirstChild('Torso') == nil then
  969. if thatthing.Character:FindFirstChild('UpperTorso') then
  970. selectedpart = "UpperTorso"
  971. else
  972. selectedpart = "Head"
  973. end
  974. end
  975. end
  976. local good = true
  977. if lasttarg and lasttarg:FindFirstChildOfClass('Humanoid') and lasttarg:FindFirstChildOfClass('Humanoid').Health <= 0 then
  978. recentlyded = 20
  979. lasttarg = nil
  980. end
  981. if recentlyded > 0 then
  982. good = false
  983. recentlyded = recentlyded - 1
  984. else
  985. good = true
  986. end
  987. if thatthing and thatthing.Character and Camera and good then
  988. lasttarg = thatthing.Character
  989. end
  990. if distance(game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame.p,thatthing.Character[selectedpart].CFrame.p,true) > 1029 then
  991. for i=1,7 do
  992. if thatthing and thatthing.Character and Camera and good == true then
  993. Camera.CFrame = Camera.CFrame:lerp(CFrame.new(Camera.CFrame.p,thatthing.Character[selectedpart].CFrame.p),i/5)
  994. end
  995. wait()
  996. end
  997. else
  998. Camera.CFrame = CFrame.new(Camera.CFrame.p,thatthing.Character[selectedpart].CFrame.p)
  999. end
  1000. end
  1001. end
  1002. end
  1003. end)
  1004.  
  1005. game.Players.PlayerRemoving:connect(function(pla)
  1006. for i,v in pairs(plrs) do
  1007. if v == pla then
  1008. table.remove(plrs,i)
  1009. end
  1010. end
  1011. end)
  1012. game:GetService('Teams').ChildRemoved:connect(function(child)
  1013. for i,v in pairs(tms) do
  1014. if v == child then
  1015. table.remove(tms,i)
  1016. end
  1017. end
  1018. end)
  1019.  
  1020. while true do
  1021. for i,v in pairs(workspace.CurrentCamera:GetChildren()) do
  1022. if v.Name == "PATH BOI" then
  1023. v:Destroy()
  1024. end
  1025. end
  1026. for i,v in pairs(players:GetChildren()) do
  1027. v:Destroy()
  1028. end
  1029. for i,v in pairs(teams:GetChildren()) do
  1030. v:Destroy()
  1031. end
  1032. local thatnum = 0
  1033. for i,v in pairs(game:GetService('Teams'):GetChildren()) do
  1034. if v ~= game.Players.LocalPlayer.Team then
  1035. local team = Instance.new('TextButton',teams)
  1036. if thatnum > 4 then
  1037. teams.CanvasSize = UDim2.new(0,0,0,(thatnum*(teams.AbsoluteSize.Y/5))+(teams.AbsoluteSize.Y/5))
  1038. else
  1039. teams.CanvasSize = UDim2.new(0,0,0,0)
  1040. end
  1041. team.Name = v.Name
  1042. team.TextScaled = true
  1043. team.Text = v.Name
  1044. team.Size = UDim2.new(1,0,0,teams.AbsoluteSize.Y/5)
  1045. team.Position = UDim2.new(0,0,0,(thatnum*(teams.AbsoluteSize.Y/5)))
  1046. team.BackgroundTransparency = 1
  1047. team.TextColor3 = Color3.new(1,0,0)
  1048. for c,a in pairs(tms) do
  1049. if a == v then
  1050. team.TextColor3 = Color3.new(0,1,0)
  1051. end
  1052. end
  1053. team.MouseButton1Click:connect(function()
  1054. local found = false
  1055. for c,a in pairs(tms) do
  1056. if a == v then
  1057. table.remove(tms,c)
  1058. found = true
  1059. team.TextColor3 = Color3.new(1,0,0)
  1060. end
  1061. end
  1062. if found == false then
  1063. table.insert(tms,v)
  1064. team.TextColor3 = Color3.new(0,1,0)
  1065. end
  1066. end)
  1067. thatnum = thatnum+1
  1068. end
  1069. end
  1070. local thatnum2 = 0
  1071. for i,v in pairs(game:GetService('Players'):GetChildren()) do
  1072. if v ~= game.Players.LocalPlayer then
  1073. local team = Instance.new('TextButton',players)
  1074. if thatnum2 > 4 then
  1075. players.CanvasSize = UDim2.new(0,0,0,(thatnum2*(players.AbsoluteSize.Y/5))+(players.AbsoluteSize.Y/5))
  1076. else
  1077. players.CanvasSize = UDim2.new(0,0,0,0)
  1078. end
  1079. team.Name = v.Name
  1080. team.TextScaled = true
  1081. team.Text = v.Name
  1082. team.Size = UDim2.new(1,0,0,players.AbsoluteSize.Y/5)
  1083. team.Position = UDim2.new(0,0,0,(thatnum2*(players.AbsoluteSize.Y/5)))
  1084. team.BackgroundTransparency = 1
  1085. team.TextColor3 = Color3.new(1,0,0)
  1086. for c,a in pairs(plrs) do
  1087. if a == v then
  1088. team.TextColor3 = Color3.new(0,1,0)
  1089. end
  1090. end
  1091. team.MouseButton1Click:connect(function()
  1092. local found = false
  1093. for c,a in pairs(plrs) do
  1094. if a == v then
  1095. table.remove(plrs,c)
  1096. found = true
  1097. team.TextColor3 = Color3.new(1,0,0)
  1098. end
  1099. end
  1100. if found == false then
  1101. table.insert(plrs,v)
  1102. team.TextColor3 = Color3.new(0,1,0)
  1103. end
  1104. end)
  1105. thatnum2 = thatnum2+1
  1106. end
  1107. end
  1108. if path then
  1109. if plr.Character and plr.Character:FindFirstChild('HumanoidRootPart') and thatthing and thatthing.Character and thatthing.Character:FindFirstChild('HumanoidRootPart') then
  1110. local pat = game:GetService('PathfindingService'):ComputeSmoothPathAsync(plr.Character.HumanoidRootPart.Position,thatthing.Character.HumanoidRootPart.Position,512)
  1111. if pat.Status == Enum.PathStatus.Success or pat.Status == Enum.PathStatus.ClosestOutOfRange then
  1112. local pa = pat:GetPointCoordinates()
  1113. local fol = Instance.new('Folder',workspace.CurrentCamera)
  1114. fol.Name = "PATH BOI"
  1115. local first = nil
  1116. for i,v in pairs(pa) do
  1117. if first ~= nil then
  1118. local pathfindpart = Instance.new('Part',fol)
  1119. local dist,place = getdatray(first,v)
  1120. pathfindpart.BrickColor = BrickColor.new('Really red')
  1121. pathfindpart.Size = Vector3.new(0.2,0.2,dist)
  1122. pathfindpart.Transparency = 0.5
  1123. pathfindpart.Material = Enum.Material.Neon
  1124. pathfindpart.Anchored = true
  1125. pathfindpart.CanCollide = false
  1126. pathfindpart.CFrame = place
  1127. end
  1128. first = v
  1129. end
  1130. end
  1131. end
  1132. end
  1133. wait(1)
  1134. end
  1135.  
  1136.  
  1137. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement