Advertisement
RamenRon

mm

Jul 8th, 2019
178
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 19.03 KB | None | 0 0
  1. local plr = game:GetService('Players').LocalPlayer
  2. local haaa = false
  3. local mou = plr:GetMouse()
  4. local aimkey = "e"
  5. local toggle = true
  6. local teamkey = "q"
  7. local pathkey = "r"
  8. local wallkey = "t"
  9. local tk = false
  10. local path = false
  11. local nearmouse = false
  12. local pastpath = nil
  13. local editing = nil
  14. local walls = true
  15. local plrs = {}
  16. local tms = {}
  17.  
  18. function sameteam(player,player2)
  19. local good = false
  20. if player.TeamColor == player2.TeamColor then
  21. good = true
  22. end
  23. return good
  24. end
  25.  
  26. function distance(point1,point2,heck)
  27. local result = math.huge
  28. if nearmouse == false and (heck == false or heck == nil) then
  29. result = (point1-point2).magnitude
  30. else
  31. local hmm,eh = workspace.CurrentCamera:WorldToViewportPoint(point2)
  32. print((workspace.CurrentCamera.ViewportSize-Vector2.new(0,hmm.X,0,hmm.Y)).magnitude)
  33. return (workspace.CurrentCamera.ViewportSize-Vector2.new(0,hmm.X,0,hmm.Y)).magnitude
  34. end
  35. print(result)
  36. return result
  37. end
  38.  
  39. ChangeToggle.MouseButton1Click:connect(function()
  40. if toggle == true then
  41. toggle = false
  42. ChangeToggle.Text = "Current: Holding"
  43. else
  44. toggle = true
  45. ChangeToggle.Text = "Current: Toggling"
  46. end
  47. end)
  48. ChangeSelection.MouseButton1Click:connect(function()
  49. if nearmouse == true then
  50. nearmouse = false
  51. ChangeSelection.Text = "Current: Closest To Player"
  52. else
  53. nearmouse = true
  54. ChangeSelection.Text = "Current: Closest To Center of Camera"
  55. end
  56. end)
  57. ChangeAim.MouseButton1Click:connect(function()
  58. if editing == nil then
  59. ChangeAim.Text = "Press any key to change."
  60. editing = "aim"
  61. end
  62. end)
  63. ChangeWall.MouseButton1Click:connect(function()
  64. if editing == nil then
  65. ChangeWall.Text = "Press any key to change."
  66. editing = "wall"
  67. end
  68. end)
  69. ChangePath.MouseButton1Click:connect(function()
  70. if editing == nil then
  71. ChangePath.Text = "Press any key to change."
  72. editing = "path"
  73. end
  74. end)
  75. ChangeTeam.MouseButton1Click:connect(function()
  76. if editing == nil then
  77. ChangeTeam.Text = "Press any key to change."
  78. editing = "team"
  79. end
  80. end)
  81.  
  82. function cansee(targ)
  83. local cam = workspace.CurrentCamera
  84. local ray = Ray.new(plr.Character.Head.CFrame.p, (targ.CFrame.p - plr.Character.Head.CFrame.p).unit * 300)
  85. local part, position = workspace:FindPartOnRayWithIgnoreList(ray, {plr.Character}, false, true)
  86. if part then
  87. local humanoid = part.Parent:FindFirstChildOfClass("Humanoid")
  88.  
  89. if not humanoid then
  90. humanoid = part.Parent.Parent:FindFirstChildOfClass("Humanoid")
  91. end
  92.  
  93. if humanoid and targ and humanoid.Parent == targ.Parent then
  94. local blah,actualthing = cam:WorldToScreenPoint(targ.Position)
  95. if actualthing == true then
  96. return true
  97. else
  98. return false
  99. end
  100. else
  101. return false
  102. end
  103. else
  104. return false
  105. end
  106. end
  107.  
  108. function getdatray(pointuno,pointdos)
  109. local ray = Ray.new(pointdos,(pointdos - pointuno).unit * 300)
  110. local distance = (pointuno - pointdos).magnitude
  111. local pos = CFrame.new(pointuno, pointdos) * CFrame.new(0, 0, -distance / 2)
  112. return distance,pos
  113. end
  114.  
  115. mou.Button2Down:connect(function()
  116. if editing ~= nil then
  117. if editing == "aim" then
  118. aimkey = "RMB"
  119. if haaa then
  120. aimbot.Text = "Press RMB to toggle aimbot off."
  121. else
  122. aimbot.Text = "Press RMB to toggle aimbot on."
  123. end
  124. ChangeAim.Text = "Current: RMB"
  125. elseif editing == "team" then
  126. teamkey = "RMB"
  127. if tk then
  128. teamselect.Text = "Press RMB to toggle teamkill off."
  129. else
  130. teamselect.Text = "Press RMB to toggle teamkill on."
  131. end
  132. ChangeTeam.Text = "Current: RMB"
  133. elseif editing == "path" then
  134. pathkey = "RMB"
  135. if path then
  136. pathfind.Text = "Press RMB to toggle pathfinding off."
  137. else
  138. pathfind.Text = "Press RMB to toggle pathfinding on."
  139. end
  140. ChangePath.Text = "Current: RMB"
  141. elseif editing == "wall" then
  142. wallkey = "RMB"
  143. if walls then
  144. wallselect.Text = "Press RMB to toggle aiming through walls off."
  145. else
  146. wallselect.Text = "Press RMB to toggle aiming through walls on."
  147. end
  148. ChangeWall.Text = "Current: RMB"
  149. end
  150. editing = nil
  151. else
  152. if aimkey == "RMB" then
  153. if haaa and toggle == true then
  154. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot on."
  155. haaa = false
  156. elseif haaa == false then
  157. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot off."
  158. haaa = true
  159. end
  160. elseif teamkey == "RMB" then
  161. if tk then
  162. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill on."
  163. tk = false
  164. else
  165. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill off."
  166. tk = true
  167. end
  168. elseif pathkey == "RMB" then
  169. if path then
  170. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding on."
  171. path = false
  172. else
  173. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding off."
  174. path = true
  175. end
  176. elseif wallkey == "RMB" then
  177. if walls then
  178. walls = false
  179. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls on."
  180. else
  181. walls = true
  182. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls off."
  183. end
  184. end
  185. end
  186. end)
  187.  
  188. mou.Button2Up:connect(function()
  189. if aimkey == "RMB" and toggle == false then
  190. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot on."
  191. haaa = false
  192. end
  193. end)
  194.  
  195. mou.KeyDown:connect(function(key)
  196. if editing ~= nil then
  197. if editing == "aim" then
  198. aimkey = key
  199. if haaa then
  200. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot off."
  201. else
  202. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot on."
  203. end
  204. ChangeAim.Text = "Current: "..string.upper(key)
  205. elseif editing == "team" then
  206. teamkey = key
  207. if tk then
  208. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill off."
  209. else
  210. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill on."
  211. end
  212. ChangeTeam.Text = "Current: "..string.upper(key)
  213. elseif editing == "path" then
  214. pathkey = key
  215. if path then
  216. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding off."
  217. else
  218. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding on."
  219. end
  220. ChangePath.Text = "Current: "..string.upper(key)
  221. elseif editing == "wall" then
  222. wallkey = key
  223. if walls then
  224. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls off."
  225. else
  226. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls on."
  227. end
  228. ChangeWall.Text = "Current: "..string.upper(key)
  229. end
  230. editing = nil
  231. elseif key == "p" then
  232. Chat.Enabled = not Chat.Enabled
  233. elseif key == "l" then
  234. ScreenGui.Enabled = not ScreenGui.Enabled
  235. elseif key == teamkey then
  236. if tk then
  237. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill on."
  238. tk = false
  239. else
  240. teamselect.Text = "Press "..string.upper(teamkey).." to toggle teamkill off."
  241. tk = true
  242. end
  243. elseif key == aimkey then
  244. if haaa and toggle == true then
  245. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot on."
  246. haaa = false
  247. elseif haaa == false then
  248. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot off."
  249. haaa = true
  250. end
  251. elseif key == pathkey then
  252. if path then
  253. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding on."
  254. path = false
  255. else
  256. pathfind.Text = "Press "..string.upper(pathkey).." to toggle pathfinding off."
  257. path = true
  258. end
  259. elseif key == wallkey then
  260. if walls then
  261. walls = false
  262. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls on."
  263. else
  264. walls = true
  265. wallselect.Text = "Press "..string.upper(wallkey).." to toggle aiming through walls off."
  266. end
  267. end
  268. end)
  269.  
  270. mou.KeyUp:connect(function(key)
  271. if key == aimkey and toggle == false then
  272. aimbot.Text = "Press "..string.upper(aimkey).." to toggle aimbot on."
  273. haaa = false
  274. end
  275. end)
  276.  
  277. local thatthing = nil
  278. local Camera = workspace.CurrentCamera
  279. local bestdist = nil
  280. local setpart = "Head"
  281. local selectedpart = "Head"
  282. local canseenearest = false
  283.  
  284. head.MouseButton1Click:connect(function()
  285. righta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  286. lefta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  287. rightl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  288. leftl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  289. torso.BackgroundColor3 = Color3.fromRGB(255,0,0)
  290. head.BackgroundColor3 = Color3.fromRGB(0,255,0)
  291. setpart = "Head"
  292. end)
  293. torso.MouseButton1Click:connect(function()
  294. righta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  295. lefta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  296. rightl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  297. leftl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  298. torso.BackgroundColor3 = Color3.fromRGB(0,255,0)
  299. head.BackgroundColor3 = Color3.fromRGB(255,0,0)
  300. setpart = "Torso"
  301. end)
  302. righta.MouseButton1Click:connect(function()
  303. righta.BackgroundColor3 = Color3.fromRGB(0,255,0)
  304. lefta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  305. rightl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  306. leftl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  307. torso.BackgroundColor3 = Color3.fromRGB(255,0,0)
  308. head.BackgroundColor3 = Color3.fromRGB(255,0,0)
  309. setpart = "Right Arm"
  310. end)
  311. lefta.MouseButton1Click:connect(function()
  312. righta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  313. lefta.BackgroundColor3 = Color3.fromRGB(0,255,0)
  314. rightl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  315. leftl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  316. torso.BackgroundColor3 = Color3.fromRGB(255,0,0)
  317. head.BackgroundColor3 = Color3.fromRGB(255,0,0)
  318. setpart = "Left Arm"
  319. end)
  320. rightl.MouseButton1Click:connect(function()
  321. righta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  322. lefta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  323. rightl.BackgroundColor3 = Color3.fromRGB(0,255,0)
  324. leftl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  325. torso.BackgroundColor3 = Color3.fromRGB(255,0,0)
  326. head.BackgroundColor3 = Color3.fromRGB(255,0,0)
  327. setpart = "Right Leg"
  328. end)
  329. leftl.MouseButton1Click:connect(function()
  330. righta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  331. lefta.BackgroundColor3 = Color3.fromRGB(255,0,0)
  332. rightl.BackgroundColor3 = Color3.fromRGB(255,0,0)
  333. leftl.BackgroundColor3 = Color3.fromRGB(0,255,0)
  334. torso.BackgroundColor3 = Color3.fromRGB(255,0,0)
  335. head.BackgroundColor3 = Color3.fromRGB(255,0,0)
  336. setpart = "Left Leg"
  337. end)
  338. local recentlyded = 0
  339. local lasttarg = nil
  340. game:GetService('RunService').Stepped:connect(function(time,thing)
  341. thatthing = nil
  342. canseenearest = false
  343. selectedpart = setpart
  344. Camera = workspace.CurrentCamera
  345. bestdist = nil
  346. if haaa or path then
  347. if walls == false then
  348. canseenearest = true
  349. end
  350. for i,v in pairs(game:GetService('Players'):GetChildren()) do
  351. if v ~= game:GetService('Players').LocalPlayer and v.Character and v.Character:FindFirstChild('Head') and v.Character:FindFirstChildOfClass('Humanoid') and v.Character:FindFirstChildOfClass('Humanoid').Health > 0 then
  352. if tk == false and (sameteam(v,plr) == false or game:GetService('Players').LocalPlayer.Team == nil) then
  353. if bestdist == nil or distance(game:GetService('Players').LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p) < bestdist or (canseenearest == false and cansee(v.Character.Head)) then
  354. local gudguy = false
  355. for a,c in pairs(tms) do
  356. if v.TeamColor == c.TeamColor then
  357. gudguy = true
  358. end
  359. end
  360. for a,c in pairs(plrs) do
  361. if v == c then
  362. gudguy = true
  363. end
  364. end
  365. if gudguy == false then
  366. if canseenearest == true and cansee(v.Character.Head) then
  367. thatthing = v
  368. bestdist = distance(game:GetService('Players').LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p)
  369. elseif canseenearest == false then
  370. if cansee(v.Character.Head) then
  371. canseenearest = true
  372. end
  373. thatthing = v
  374. bestdist = distance(game:GetService('Players').LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p)
  375. end
  376. end
  377. end
  378. elseif tk == true then
  379. if bestdist == nil or distance(game:GetService('Players').LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p) < bestdist or (canseenearest == false and cansee(v.Character.Head)) and (sameteam(v,plr) == false or game:GetService('Players').LocalPlayer.Team == nil) then
  380. local gudguy = false
  381. for a,c in pairs(plrs) do
  382. if v == c then
  383. gudguy = true
  384. end
  385. end
  386. for a,c in pairs(tms) do
  387. if v.TeamColor == c.TeamColor then
  388. gudguy = true
  389. end
  390. end
  391. if gudguy == false then
  392. if canseenearest == true and cansee(v.Character.Head) then
  393. thatthing = v
  394. bestdist = distance(game:GetService('Players').LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p)
  395. elseif canseenearest == false then
  396. if cansee(v.Character.Head) then
  397. canseenearest = true
  398. end
  399. thatthing = v
  400. bestdist = distance(game:GetService('Players').LocalPlayer.Character.HumanoidRootPart.CFrame.p,v.Character.HumanoidRootPart.CFrame.p)
  401. end
  402. end
  403. end
  404. end
  405. end
  406. end
  407. if thatthing ~= nil and bestdist ~= nil and plr.Character:FindFirstChild('HumanoidRootPart') and thatthing.Character:FindFirstChild('HumanoidRootPart') then
  408. if haaa then
  409. if selectedpart == "Right Arm" then
  410. if thatthing.Character:FindFirstChild('Right Arm') == nil then
  411. if thatthing.Character:FindFirstChild('RightLowerArm') then
  412. selectedpart = "RightLowerArm"
  413. else
  414. selectedpart = "Head"
  415. end
  416. end
  417. elseif selectedpart == "Left Arm" then
  418. if thatthing.Character:FindFirstChild('Left Arm') == nil then
  419. if thatthing.Character:FindFirstChild('LeftLowerArm') then
  420. selectedpart = "LeftLowerArm"
  421. else
  422. selectedpart = "Head"
  423. end
  424. end
  425. elseif selectedpart == "Left Leg" then
  426. if thatthing.Character:FindFirstChild('Left Leg') == nil then
  427. if thatthing.Character:FindFirstChild('LeftLowerLeg') then
  428. selectedpart = "LeftLowerLeg"
  429. else
  430. selectedpart = "Head"
  431. end
  432. end
  433. elseif selectedpart == "Right Leg" then
  434. if thatthing.Character:FindFirstChild('Right Leg') == nil then
  435. if thatthing.Character:FindFirstChild('RightLowerLeg') then
  436. selectedpart = "RightLowerLeg"
  437. else
  438. selectedpart = "Head"
  439. end
  440. end
  441. elseif selectedpart == "Torso" then
  442. if thatthing.Character:FindFirstChild('Torso') == nil then
  443. if thatthing.Character:FindFirstChild('UpperTorso') then
  444. selectedpart = "UpperTorso"
  445. else
  446. selectedpart = "Head"
  447. end
  448. end
  449. end
  450. local good = true
  451. if lasttarg and lasttarg:FindFirstChildOfClass('Humanoid') and lasttarg:FindFirstChildOfClass('Humanoid').Health <= 0 then
  452. recentlyded = 20
  453. lasttarg = nil
  454. end
  455. if recentlyded > 0 then
  456. good = false
  457. recentlyded = recentlyded - 1
  458. else
  459. good = true
  460. end
  461. if thatthing and thatthing.Character and Camera and good then
  462. lasttarg = thatthing.Character
  463. end
  464. if distance(game:GetService('Players').LocalPlayer.Character.HumanoidRootPart.CFrame.p,thatthing.Character[selectedpart].CFrame.p,true) > 1029 then
  465. for i=1,7 do
  466. if thatthing and thatthing.Character and Camera and good == true then
  467. Camera.CFrame = Camera.CFrame:lerp(CFrame.new(Camera.CFrame.p,thatthing.Character[selectedpart].CFrame.p),i/5)
  468. end
  469. wait()
  470. end
  471. else
  472. Camera.CFrame = CFrame.new(Camera.CFrame.p,thatthing.Character[selectedpart].CFrame.p)
  473. end
  474. end
  475. end
  476. end
  477. end)
  478.  
  479. game:GetService('Players').PlayerRemoving:connect(function(pla)
  480. for i,v in pairs(plrs) do
  481. if v == pla then
  482. table.remove(plrs,i)
  483. end
  484. end
  485. end)
  486. game:GetService('Teams').ChildRemoved:connect(function(child)
  487. for i,v in pairs(tms) do
  488. if v == child then
  489. table.remove(tms,i)
  490. end
  491. end
  492. end)
  493.  
  494. while true do
  495. for i,v in pairs(workspace.CurrentCamera:GetChildren()) do
  496. if v.Name == "PATH BOI" then
  497. v:Destroy()
  498. end
  499. end
  500. for i,v in pairs(players:GetChildren()) do
  501. v:Destroy()
  502. end
  503. for i,v in pairs(teams:GetChildren()) do
  504. v:Destroy()
  505. end
  506. local thatnum = 0
  507. for i,v in pairs(game:GetService('Teams'):GetChildren()) do
  508. if v.TeamColor ~= game:GetService('Players').LocalPlayer.TeamColor then
  509. local team = Instance.new('TextButton',teams)
  510. if thatnum > 4 then
  511. teams.CanvasSize = UDim2.new(0,0,0,(thatnum*(teams.AbsoluteSize.Y/5))+(teams.AbsoluteSize.Y/5))
  512. else
  513. teams.CanvasSize = UDim2.new(0,0,0,0)
  514. end
  515. team.Name = v.Name
  516. team.TextScaled = true
  517. team.Text = v.Name
  518. team.Size = UDim2.new(1,0,0,teams.AbsoluteSize.Y/5)
  519. team.Position = UDim2.new(0,0,0,(thatnum*(teams.AbsoluteSize.Y/5)))
  520. team.BackgroundTransparency = 1
  521. team.TextColor3 = Color3.new(1,0,0)
  522. for c,a in pairs(tms) do
  523. if a == v then
  524. team.TextColor3 = Color3.new(0,1,0)
  525. end
  526. end
  527. team.MouseButton1Click:connect(function()
  528. local found = false
  529. for c,a in pairs(tms) do
  530. if a == v then
  531. table.remove(tms,c)
  532. found = true
  533. team.TextColor3 = Color3.new(1,0,0)
  534. end
  535. end
  536. if found == false then
  537. table.insert(tms,v)
  538. team.TextColor3 = Color3.new(0,1,0)
  539. end
  540. end)
  541. thatnum = thatnum+1
  542. end
  543. end
  544. local thatnum2 = 0
  545. for i,v in pairs(game:GetService('Players'):GetChildren()) do
  546. if v ~= game:GetService('Players').LocalPlayer then
  547. local team = Instance.new('TextButton',players)
  548. if thatnum2 > 4 then
  549. players.CanvasSize = UDim2.new(0,0,0,(thatnum2*(players.AbsoluteSize.Y/5))+(players.AbsoluteSize.Y/5))
  550. else
  551. players.CanvasSize = UDim2.new(0,0,0,0)
  552. end
  553. team.Name = v.Name
  554. team.TextScaled = true
  555. team.Text = v.Name
  556. team.Size = UDim2.new(1,0,0,players.AbsoluteSize.Y/5)
  557. team.Position = UDim2.new(0,0,0,(thatnum2*(players.AbsoluteSize.Y/5)))
  558. team.BackgroundTransparency = 1
  559. team.TextColor3 = Color3.new(1,0,0)
  560. for c,a in pairs(plrs) do
  561. if a == v then
  562. team.TextColor3 = Color3.new(0,1,0)
  563. end
  564. end
  565. team.MouseButton1Click:connect(function()
  566. local found = false
  567. for c,a in pairs(plrs) do
  568. if a == v then
  569. table.remove(plrs,c)
  570. found = true
  571. team.TextColor3 = Color3.new(1,0,0)
  572. end
  573. end
  574. if found == false then
  575. table.insert(plrs,v)
  576. team.TextColor3 = Color3.new(0,1,0)
  577. end
  578. end)
  579. thatnum2 = thatnum2+1
  580. end
  581. end
  582. if path then
  583. if plr.Character and plr.Character:FindFirstChild('HumanoidRootPart') and thatthing and thatthing.Character and thatthing.Character:FindFirstChild('HumanoidRootPart') then
  584. local pat = game:GetService('PathfindingService'):ComputeSmoothPathAsync(plr.Character.HumanoidRootPart.Position,thatthing.Character.HumanoidRootPart.Position,512)
  585. if pat.Status == Enum.PathStatus.Success or pat.Status == Enum.PathStatus.ClosestOutOfRange then
  586. local pa = pat:GetPointCoordinates()
  587. local fol = Instance.new('Folder',workspace.CurrentCamera)
  588. fol.Name = "PATH BOI"
  589. local first = nil
  590. for i,v in pairs(pa) do
  591. if first ~= nil then
  592. local pathfindpart = Instance.new('Part',fol)
  593. local dist,place = getdatray(first,v)
  594. pathfindpart.BrickColor = BrickColor.new('Really red')
  595. pathfindpart.Size = Vector3.new(0.2,0.2,dist)
  596. pathfindpart.Transparency = 0.5
  597. pathfindpart.Material = Enum.Material.Neon
  598. pathfindpart.Anchored = true
  599. pathfindpart.CanCollide = false
  600. pathfindpart.CFrame = place
  601. end
  602. first = v
  603. end
  604. end
  605. end
  606. end
  607. wait(1)
  608. end
  609.  
  610.  
  611. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement