Advertisement
Liu-2

Laser Gun - [ Roblox ]

Jul 2nd, 2019
227
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 54.29 KB | None | 0 0
  1. --- [[ Laser gun ]] ---
  2. -- by fo43123
  3.  
  4. local me = game.Players.LocalPlayer
  5. local mouse = me:GetMouse()
  6. local char = me.Character
  7. local hum = char['Humanoid']
  8. local hd = char['Head']
  9. local ts = char['Torso']
  10. local ra = char['Right Arm']
  11. local la = char['Left Arm']
  12. local rl = char['Right Leg']
  13. local ll = char['Left Leg']
  14. local root = char['HumanoidRootPart']
  15. local rj = root['RootJoint']
  16. local rs = ts['Right Shoulder']
  17. local ls = ts['Left Shoulder']
  18. local rh = ts['Right Hip']
  19. local lh = ts['Left Hip']
  20. local nk = ts['Neck']
  21. local animate = char:FindFirstChild('Animate')
  22. local bases = workspace:FindFirstChild('Baseplate') or workspace:FindFirstChild('Base')
  23. local anim = nil
  24. local cananim = true
  25. local equipped = false
  26. local attack = false
  27. local onrun = false
  28. local isonhit = false
  29. local sine = 0
  30. local change = 1
  31. local cc = workspace.CurrentCamera
  32. local cos = math.cos
  33. local sin = math.sin
  34. local rad = math.rad
  35. local rand = math.random
  36. local cfn = CFrame.new
  37. local cfa = CFrame.Angles
  38. local cfor = CFrame.fromOrientation
  39. local v3 = Vector3.new
  40. local sicko = Instance.new('Sound', hd)
  41. sicko.Volume = 1.5
  42. sicko.SoundId = 'rbxassetid://1722896592'
  43. sicko.Looped = true
  44. sicko:Play()
  45. hum.WalkSpeed = 19.99
  46. print([[
  47.     -- MoveList --
  48.     LMB - Laser Shoot
  49.     F - Charged Shoot
  50.     Q - Toggle Run
  51.     M - Toggle Music
  52. ]])
  53.  
  54. local RIGHTARMLERP = Instance.new('ManualWeld', ts)
  55. RIGHTARMLERP.Part0 = ts
  56. RIGHTARMLERP.Part1 = ra
  57. RIGHTARMLERP.C0 = cfn(1.5, 0, 0) * cfa(rad(0), rad(0), rad(0))
  58. local LEFTARMLERP = Instance.new('ManualWeld', ts)
  59. LEFTARMLERP.Part0 = ts
  60. LEFTARMLERP.Part1 = la
  61. LEFTARMLERP.C0 = cfn(-1.5, 0, 0) * cfa(rad(0), rad(0), rad(0))
  62. local HEADLERP = Instance.new('ManualWeld', ts)
  63. HEADLERP.Part0 = ts
  64. HEADLERP.Part1 = hd
  65. HEADLERP.C0 = cfn(0, 1.5, 0) * cfa(rad(0), rad(0), rad(0))
  66. local RIGHTLEGLERP = Instance.new('ManualWeld', ts)
  67. RIGHTLEGLERP.Part0 = root
  68. RIGHTLEGLERP.Part1 = rl
  69. RIGHTLEGLERP.C0 = cfn(0.5, -2, 0) * cfa(rad(0), rad(0), rad(0))
  70. local LEFTLEGLERP = Instance.new('ManualWeld', ts)
  71. LEFTLEGLERP.Part0 = root
  72. LEFTLEGLERP.Part1 = ll
  73. LEFTLEGLERP.C0 = cfn(-0.5, -2, 0) * cfa(rad(0), rad(0), rad(0))
  74. local TORSOLERP = Instance.new('ManualWeld', ts)
  75. TORSOLERP.Part0 = root
  76. TORSOLERP.Part1 = ts
  77. TORSOLERP.C0 = cfn(0, 0, 0) * cfa(rad(0), rad(0), rad(0))
  78.  
  79. -- laser gun model
  80. --Converted with ttyyuu12345's model to script plugin v4
  81. function sandbox(var,func)
  82.     local env = getfenv(func)
  83.     local newenv = setmetatable({},{
  84.         __index = function(self,k)
  85.             if k=="script" then
  86.                 return var
  87.             else
  88.                 return env[k]
  89.             end
  90.         end,
  91.     })
  92.     setfenv(func,newenv)
  93.     return func
  94. end
  95. cors = {}
  96. mas = Instance.new('Model', char)
  97. mas.Name = 'LaserGun'
  98. effects = Instance.new('Folder', char)
  99. effects.Name = 'Effects'
  100. Part0 = Instance.new("Part")
  101. Part1 = Instance.new("Part")
  102. Part2 = Instance.new("Part")
  103. Part3 = Instance.new("Part")
  104. Part4 = Instance.new("Part")
  105. Part5 = Instance.new("Part")
  106. Part6 = Instance.new("Part")
  107. ManualWeld7 = Instance.new("ManualWeld")
  108. ManualWeld8 = Instance.new("ManualWeld")
  109. ManualWeld9 = Instance.new("ManualWeld")
  110. ManualWeld10 = Instance.new("ManualWeld")
  111. ManualWeld11 = Instance.new("ManualWeld")
  112. ManualWeld12 = Instance.new("ManualWeld")
  113. ManualWeld13 = Instance.new("ManualWeld")
  114. ManualWeld14 = Instance.new("ManualWeld")
  115. ManualWeld15 = Instance.new("ManualWeld")
  116. ManualWeld16 = Instance.new("ManualWeld")
  117. ManualWeld17 = Instance.new("ManualWeld")
  118. ManualWeld18 = Instance.new("ManualWeld")
  119. ManualWeld19 = Instance.new("ManualWeld")
  120. ManualWeld20 = Instance.new("ManualWeld")
  121. ManualWeld21 = Instance.new("ManualWeld")
  122. ManualWeld22 = Instance.new("ManualWeld")
  123. ManualWeld23 = Instance.new("ManualWeld")
  124. ManualWeld24 = Instance.new("ManualWeld")
  125. ManualWeld25 = Instance.new("ManualWeld")
  126. ManualWeld26 = Instance.new("ManualWeld")
  127. ManualWeld27 = Instance.new("ManualWeld")
  128. ManualWeld28 = Instance.new("ManualWeld")
  129. ManualWeld29 = Instance.new("ManualWeld")
  130. ManualWeld30 = Instance.new("ManualWeld")
  131. ManualWeld31 = Instance.new("ManualWeld")
  132. ManualWeld32 = Instance.new("ManualWeld")
  133. ManualWeld33 = Instance.new("ManualWeld")
  134. ManualWeld34 = Instance.new("ManualWeld")
  135. ManualWeld35 = Instance.new("ManualWeld")
  136. ManualWeld36 = Instance.new("ManualWeld")
  137. ManualWeld37 = Instance.new("ManualWeld")
  138. ManualWeld38 = Instance.new("ManualWeld")
  139. ManualWeld39 = Instance.new("ManualWeld")
  140. ManualWeld40 = Instance.new("ManualWeld")
  141. ManualWeld41 = Instance.new("ManualWeld")
  142. ManualWeld42 = Instance.new("ManualWeld")
  143. ManualWeld43 = Instance.new("ManualWeld")
  144. ManualWeld44 = Instance.new("ManualWeld")
  145. ManualWeld45 = Instance.new("ManualWeld")
  146. ManualWeld46 = Instance.new("ManualWeld")
  147. ManualWeld47 = Instance.new("ManualWeld")
  148. ManualWeld48 = Instance.new("ManualWeld")
  149. gripweld = Instance.new('ManualWeld')
  150. Part49 = Instance.new("Part")
  151. Part50 = Instance.new("Part")
  152. Part51 = Instance.new("Part")
  153. Part52 = Instance.new("Part")
  154. Part53 = Instance.new("Part")
  155. Part54 = Instance.new("Part")
  156. Part55 = Instance.new("Part")
  157. Part56 = Instance.new("Part")
  158. Part57 = Instance.new("Part")
  159. Part58 = Instance.new("Part")
  160. Part59 = Instance.new("Part")
  161. Part60 = Instance.new("Part")
  162. Part61 = Instance.new("Part")
  163. Part62 = Instance.new("Part")
  164. Part63 = Instance.new("Part")
  165. Part64 = Instance.new("Part")
  166. Part65 = Instance.new("Part")
  167. Part66 = Instance.new("Part")
  168. Part67 = Instance.new("Part")
  169. Part68 = Instance.new("Part")
  170. Part69 = Instance.new("Part")
  171. Part70 = Instance.new("Part")
  172. Part71 = Instance.new("Part")
  173. Part72 = Instance.new("Part")
  174. Part73 = Instance.new("Part")
  175. Part74 = Instance.new("Part")
  176. Part75 = Instance.new("Part")
  177. Part76 = Instance.new("Part")
  178. Part77 = Instance.new("Part")
  179. Part78 = Instance.new("Part")
  180. Part79 = Instance.new("Part")
  181. Part80 = Instance.new("Part")
  182. Part81 = Instance.new("Part")
  183. Part82 = Instance.new("Part")
  184. Part0.Name = "a5"
  185. Part0.Parent = mas
  186. Part0.CFrame = CFrame.new(0.44999975, 0.269999921, 0.00499999709, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  187. Part0.Position = Vector3.new(0.44999975, 0.269999921, 0.00499999709)
  188. Part0.Size = Vector3.new(0.0799999386, 0.400000036, 0.200000077)
  189. Part0.BottomSurface = Enum.SurfaceType.Smooth
  190. Part0.CanCollide = false
  191. Part0.Material = Enum.Material.DiamondPlate
  192. Part0.TopSurface = Enum.SurfaceType.Smooth
  193. Part1.Name = "d9"
  194. Part1.Parent = mas
  195. Part1.CFrame = CFrame.new(0.0899997056, 0.440000147, 0.185000196, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  196. Part1.Position = Vector3.new(0.0899997056, 0.440000147, 0.185000196)
  197. Part1.Color = Color3.new(0.654902, 0.368627, 0.607843)
  198. Part1.Size = Vector3.new(3.86000013, 1, 0.150000468)
  199. Part1.BottomSurface = Enum.SurfaceType.Smooth
  200. Part1.BrickColor = BrickColor.new("Lilac")
  201. Part1.CanCollide = false
  202. Part1.Material = Enum.Material.Neon
  203. Part1.TopSurface = Enum.SurfaceType.Smooth
  204. Part1.brickColor = BrickColor.new("Lilac")
  205. Part1.Shape = Enum.PartType.Cylinder
  206. Part2.Name = "d16"
  207. Part2.Parent = mas
  208. Part2.CFrame = CFrame.new(1.54499984, 1.48000097, 0.0149999876, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  209. Part2.Position = Vector3.new(1.54499984, 1.48000097, 0.0149999876)
  210. Part2.Color = Color3.new(0.388235, 0.372549, 0.384314)
  211. Part2.Size = Vector3.new(4.02999926, 0.26000011, 0.0899998695)
  212. Part2.BottomSurface = Enum.SurfaceType.Smooth
  213. Part2.BrickColor = BrickColor.new("Dark stone grey")
  214. Part2.CanCollide = false
  215. Part2.Material = Enum.Material.DiamondPlate
  216. Part2.TopSurface = Enum.SurfaceType.Smooth
  217. Part2.brickColor = BrickColor.new("Dark stone grey")
  218. Part2.Shape = Enum.PartType.Cylinder
  219. Part3.Name = "d2"
  220. Part3.Parent = mas
  221. Part3.CFrame = CFrame.new(-0.434999824, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  222. Part3.Position = Vector3.new(-0.434999824, 1, 0)
  223. Part3.Color = Color3.new(0.388235, 0.372549, 0.384314)
  224. Part3.Size = Vector3.new(0.190000013, 1.10000002, 1.10000002)
  225. Part3.BottomSurface = Enum.SurfaceType.Smooth
  226. Part3.BrickColor = BrickColor.new("Dark stone grey")
  227. Part3.CanCollide = false
  228. Part3.Material = Enum.Material.DiamondPlate
  229. Part3.TopSurface = Enum.SurfaceType.Smooth
  230. Part3.brickColor = BrickColor.new("Dark stone grey")
  231. Part3.Shape = Enum.PartType.Cylinder
  232. Part4.Name = "d1"
  233. Part4.Parent = mas
  234. Part4.CFrame = CFrame.new(2.69371295, 0.609683573, 0.175000012, 0.965925872, -0.258818984, 0, 0.258818984, 0.965925872, 0, 0, 0, 1)
  235. Part4.Orientation = Vector3.new(0, 0, 15)
  236. Part4.Position = Vector3.new(2.69371295, 0.609683573, 0.175000012)
  237. Part4.Rotation = Vector3.new(0, 0, 15)
  238. Part4.Color = Color3.new(0.654902, 0.368627, 0.607843)
  239. Part4.Size = Vector3.new(1.48999989, 0.14000003, 0.270000607)
  240. Part4.BottomSurface = Enum.SurfaceType.Smooth
  241. Part4.BrickColor = BrickColor.new("Lilac")
  242. Part4.CanCollide = false
  243. Part4.Material = Enum.Material.Neon
  244. Part4.TopSurface = Enum.SurfaceType.Smooth
  245. Part4.brickColor = BrickColor.new("Lilac")
  246. Part4.Shape = Enum.PartType.Cylinder
  247. Part5.Name = "d30"
  248. Part5.Parent = mas
  249. Part5.CFrame = CFrame.new(2.18309999, 1.07482338, -0.0850001648, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  250. Part5.Position = Vector3.new(2.18309999, 1.07482338, -0.0850001648)
  251. Part5.Color = Color3.new(0.388235, 0.372549, 0.384314)
  252. Part5.Size = Vector3.new(0.159999982, 1, 0.990000427)
  253. Part5.BottomSurface = Enum.SurfaceType.Smooth
  254. Part5.BrickColor = BrickColor.new("Dark stone grey")
  255. Part5.CanCollide = false
  256. Part5.Material = Enum.Material.DiamondPlate
  257. Part5.TopSurface = Enum.SurfaceType.Smooth
  258. Part5.brickColor = BrickColor.new("Dark stone grey")
  259. Part5.Shape = Enum.PartType.Cylinder
  260. Part6.Name = "grip""d13"
  261. Part49.Parent = mas
  262. Part49.CFrame = CFrame.new(1.35500014, 0.519999981, -1.63912773e-07, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  263. Part49.Position = Vector3.new(1.35500014, 0.519999981, -1.63912773e-07)
  264. Part49.Color = Color3.new(0.388235, 0.372549, 0.384314)
  265. Part49.Size = Vector3.new(0.25, 1, 0.600000381)
  266. Part49.BottomSurface = Enum.SurfaceType.Smooth
  267. Part49.BrickColor = BrickColor.new("Dark stone grey")
  268. Part49.CanCollide = false
  269. Part49.Material = Enum.Material.DiamondPlate
  270. Part49.TopSurface = Enum.SurfaceType.Smooth
  271. Part49.brickColor = BrickColor.new("Dark stone grey")
  272. Part49.Shape = Enum.PartType.Cylinder
  273. Part50.Name = "a6"
  274. Part50.Parent = mas
  275. Part50.CFrame = CFrame.new(0.0349999666, 0.5, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  276. Part50.Position = Vector3.new(0.0349999666, 0.5, 0)
  277. Part50.Size = Vector3.new(3.93000007, 1, 0.5)
  278. Part50.BottomSurface = Enum.SurfaceType.Smooth
  279. Part50.CanCollide = false
  280. Part50.Material = Enum.Material.DiamondPlate
  281. Part50.TopSurface = Enum.SurfaceType.Smooth
  282. Part50.Shape = Enum.PartType.Cylinder
  283. Part51.Name = "d19"
  284. Part51.Parent = mas
  285. Part51.CFrame = CFrame.new(1.54499984, 1.05000126, 0.494999945, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  286. Part51.Position = Vector3.new(1.54499984, 1.05000126, 0.494999945)
  287. Part51.Color = Color3.new(0.388235, 0.372549, 0.384314)
  288. Part51.Size = Vector3.new(4.02999926, 0.26000011, 0.0899998695)
  289. Part51.BottomSurface = Enum.SurfaceType.Smooth
  290. Part51.BrickColor = BrickColor.new("Dark stone grey")
  291. Part51.CanCollide = false
  292. Part51.Material = Enum.Material.DiamondPlate
  293. Part51.TopSurface = Enum.SurfaceType.Smooth
  294. Part51.brickColor = BrickColor.new("Dark stone grey")
  295. Part51.Shape = Enum.PartType.Cylinder
  296. Part52.Name = "main"
  297. Part52.Parent = mas
  298. Part52.CFrame = CFrame.new(0.235000014, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  299. Part52.Position = Vector3.new(0.235000014, 1, 0)
  300. Part52.Size = Vector3.new(1.47000003, 1, 1)
  301. Part52.BottomSurface = Enum.SurfaceType.Smooth
  302. Part52.CanCollide = false
  303. Part52.Material = Enum.Material.DiamondPlate
  304. Part52.TopSurface = Enum.SurfaceType.Smooth
  305. Part52.Shape = Enum.PartType.Cylinder
  306. Part53.Name = "d15"
  307. Part53.Parent = mas
  308. Part53.CFrame = CFrame.new(3.57999992, 1, -0.00999984331, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  309. Part53.Position = Vector3.new(3.57999992, 1, -0.00999984331)
  310. Part53.Color = Color3.new(0.831373, 0.564706, 0.741176)
  311. Part53.Size = Vector3.new(0.340000004, 1.10000002, 0.700000346)
  312. Part53.BottomSurface = Enum.SurfaceType.Smooth
  313. Part53.BrickColor = BrickColor.new("Sunrise")
  314. Part53.CanCollide = false
  315. Part53.Material = Enum.Material.Neon
  316. Part53.TopSurface = Enum.SurfaceType.Smooth
  317. Part53.brickColor = BrickColor.new("Sunrise")
  318. Part53.Shape = Enum.PartType.Cylinder
  319. Part54.Name = "d23"
  320. Part54.Parent = mas
  321. Part54.CFrame = CFrame.new(-0.750000477, 1.30000114, -0.124999993, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  322. Part54.Position = Vector3.new(-0.750000477, 1.30000114, -0.124999993)
  323. Part54.Color = Color3.new(0.388235, 0.372549, 0.384314)
  324. Part54.Size = Vector3.new(0.700000226, 0.26000011, 0.0899998695)
  325. Part54.BottomSurface = Enum.SurfaceType.Smooth
  326. Part54.BrickColor = BrickColor.new("Dark stone grey")
  327. Part54.CanCollide = false
  328. Part54.Material = Enum.Material.DiamondPlate
  329. Part54.TopSurface = Enum.SurfaceType.Smooth
  330. Part54.brickColor = BrickColor.new("Dark stone grey")
  331. Part54.Shape = Enum.PartType.Cylinder
  332. Part55.Name = "d21"
  333. Part55.Parent = mas
  334. Part55.CFrame = CFrame.new(3.56499934, 1, -0.0300001204, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  335. Part55.Position = Vector3.new(3.56499934, 1, -0.0300001204)
  336. Part55.Color = Color3.new(0.388235, 0.372549, 0.384314)
  337. Part55.Size = Vector3.new(0.190000013, 1.17999995, 1.37999976)
  338. Part55.BottomSurface = Enum.SurfaceType.Smooth
  339. Part55.BrickColor = BrickColor.new("Dark stone grey")
  340. Part55.CanCollide = false
  341. Part55.Material = Enum.Material.DiamondPlate
  342. Part55.TopSurface = Enum.SurfaceType.Smooth
  343. Part55.brickColor = BrickColor.new("Dark stone grey")
  344. Part55.Shape = Enum.PartType.Cylinder
  345. Part56.Name = "d28"
  346. Part56.Parent = mas
  347. Part56.CFrame = CFrame.new(3.78912425, 1, -0.0328193009, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  348. Part56.Position = Vector3.new(3.78912425, 1, -0.0328193009)
  349. Part56.Color = Color3.new(0.831373, 0.564706, 0.741176)
  350. Part56.Size = Vector3.new(0.190000013, 1.10000002, 0.710001349)
  351. Part56.BottomSurface = Enum.SurfaceType.Smooth
  352. Part56.BrickColor = BrickColor.new("Sunrise")
  353. Part56.CanCollide = false
  354. Part56.Material = Enum.Material.Neon
  355. Part56.TopSurface = Enum.SurfaceType.Smooth
  356. Part56.brickColor = BrickColor.new("Sunrise")
  357. Part56.Shape = Enum.PartType.Cylinder
  358. Part57.Name = "d11"
  359. Part57.Parent = mas
  360. Part57.CFrame = CFrame.new(-0.704999566, 0.519999981, -1.63912773e-07, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  361. Part57.Position = Vector3.new(-0.704999566, 0.519999981, -1.63912773e-07)
  362. Part57.Color = Color3.new(0.388235, 0.372549, 0.384314)
  363. Part57.Size = Vector3.new(0.25, 1, 0.600000381)
  364. Part57.BottomSurface = Enum.SurfaceType.Smooth
  365. Part57.BrickColor = BrickColor.new("Dark stone grey")
  366. Part57.CanCollide = false
  367. Part57.Material = Enum.Material.DiamondPlate
  368. Part57.TopSurface = Enum.SurfaceType.Smooth
  369. Part57.brickColor = BrickColor.new("Dark stone grey")
  370. Part57.Shape = Enum.PartType.Cylinder
  371. Part58.Name = "d20"
  372. Part58.Parent = mas
  373. Part58.CFrame = CFrame.new(-1.20499957, 0.995000005, -2.14204192e-07, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  374. Part58.Position = Vector3.new(-1.20499957, 0.995000005, -2.14204192e-07)
  375. Part58.Color = Color3.new(0.694118, 0.654902, 1)
  376. Part58.Transparency = 0.89999997615814
  377. Part58.Size = Vector3.new(0.529999971, 0.530000448, 0.620000482)
  378. Part58.BottomSurface = Enum.SurfaceType.Smooth
  379. Part58.BrickColor = BrickColor.new("Pastel violet")
  380. Part58.CanCollide = false
  381. Part58.Material = Enum.Material.Neon
  382. Part58.TopSurface = Enum.SurfaceType.Smooth
  383. Part58.brickColor = BrickColor.new("Pastel violet")
  384. Part58.Shape = Enum.PartType.Cylinder
  385. Part59.Name = "d6"
  386. Part59.Parent = mas
  387. Part59.CFrame = CFrame.new(-1.6049999, 0.48999998, -1.63912773e-07, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  388. Part59.Position = Vector3.new(-1.6049999, 0.48999998, -1.63912773e-07)
  389. Part59.Color = Color3.new(0.388235, 0.372549, 0.384314)
  390. Part59.Size = Vector3.new(0.549999893, 1, 0.600000381)
  391. Part59.BottomSurface = Enum.SurfaceType.Smooth
  392. Part59.BrickColor = BrickColor.new("Dark stone grey")
  393. Part59.CanCollide = false
  394. Part59.Material = Enum.Material.DiamondPlate
  395. Part59.TopSurface = Enum.SurfaceType.Smooth
  396. Part59.brickColor = BrickColor.new("Dark stone grey")
  397. Part59.Shape = Enum.PartType.Cylinder
  398. Part60.Name = "a4"
  399. Part60.Parent = mas
  400. Part60.CFrame = CFrame.new(0.0949999243, 0.124999948, 0.00499999709, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  401. Part60.Position = Vector3.new(0.0949999243, 0.124999948, 0.00499999709)
  402. Part60.Size = Vector3.new(0.649999857, 0.110000134, 0.200000077)
  403. Part60.BottomSurface = Enum.SurfaceType.Smooth
  404. Part60.CanCollide = false
  405. Part60.Material = Enum.Material.DiamondPlate
  406. Part60.TopSurface = Enum.SurfaceType.Smooth
  407. Part61.Name = "d25"
  408. Part61.Parent = mas
  409. Part61.CFrame = CFrame.new(2.78999925, 1.00999999, -0.00243542343, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  410. Part61.Position = Vector3.new(2.78999925, 1.00999999, -0.00243542343)
  411. Part61.Color = Color3.new(0.388235, 0.372549, 0.384314)
  412. Part61.Size = Vector3.new(0.159999982, 1, 0.850000501)
  413. Part61.BottomSurface = Enum.SurfaceType.Smooth
  414. Part61.BrickColor = BrickColor.new("Dark stone grey")
  415. Part61.CanCollide = false
  416. Part61.Material = Enum.Material.DiamondPlate
  417. Part61.TopSurface = Enum.SurfaceType.Smooth
  418. Part61.brickColor = BrickColor.new("Dark stone grey")
  419. Part61.Shape = Enum.PartType.Cylinder
  420. Part62.Name = "d29"
  421. Part62.Parent = mas
  422. Part62.CFrame = CFrame.new(3.13071442, 0.674999893, -0.0199999958, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  423. Part62.Position = Vector3.new(3.13071442, 0.674999893, -0.0199999958)
  424. Part62.Color = Color3.new(0.411765, 0.4, 0.360784)
  425. Part62.Size = Vector3.new(0.701428473, 0.17285727, 0.382000059)
  426. Part62.BottomSurface = Enum.SurfaceType.Smooth
  427. Part62.BrickColor = BrickColor.new("Flint")
  428. Part62.CanCollide = false
  429. Part62.Material = Enum.Material.DiamondPlate
  430. Part62.TopSurface = Enum.SurfaceType.Smooth
  431. Part62.brickColor = BrickColor.new("Flint")
  432. Part63.Name = "main"
  433. Part63.Parent = mas
  434. Part63.CFrame = CFrame.new(1.06499958, 1, -0.0248420238, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  435. Part63.Position = Vector3.new(1.06499958, 1, -0.0248420238)
  436. Part63.Color = Color3.new(0.388235, 0.372549, 0.384314)
  437. Part63.Size = Vector3.new(1.74999964, 1, 0.900000095)
  438. Part63.BottomSurface = Enum.SurfaceType.Smooth
  439. Part63.BrickColor = BrickColor.new("Dark stone grey")
  440. Part63.CanCollide = false
  441. Part63.Material = Enum.Material.DiamondPlate
  442. Part63.TopSurface = Enum.SurfaceType.Smooth
  443. Part63.brickColor = BrickColor.new("Dark stone grey")
  444. Part63.Shape = Enum.PartType.Cylinder
  445. Part64.Name = "d27"
  446. Part64.Parent = mas
  447. Part64.CFrame = CFrame.new(-1.12920988, 0.980000019, -0.0427353457, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  448. Part64.Position = Vector3.new(-1.12920988, 0.980000019, -0.0427353457)
  449. Part64.Color = Color3.new(0.411765, 0.4, 0.360784)
  450. Part64.Size = Vector3.new(0.190000013, 1.10000002, 0.700000286)
  451. Part64.BottomSurface = Enum.SurfaceType.Smooth
  452. Part64.BrickColor = BrickColor.new("Flint")
  453. Part64.CanCollide = false
  454. Part64.Material = Enum.Material.DiamondPlate
  455. Part64.TopSurface = Enum.SurfaceType.Smooth
  456. Part64.brickColor = BrickColor.new("Flint")
  457. Part64.Shape = Enum.PartType.Cylinder
  458. Part65.Name = "a1"
  459. Part65.Parent = mas
  460. Part65.Color = Color3.new(0.388235, 0.372549, 0.384314)
  461. Part65.Size = Vector3.new(0.390000105, 0.880000055, 0.380000412)
  462. Part65.BottomSurface = Enum.SurfaceType.Smooth
  463. Part65.BrickColor = BrickColor.new("Dark stone grey")
  464. Part65.CanCollide = false
  465. Part65.Material = Enum.Material.DiamondPlate
  466. Part65.TopSurface = Enum.SurfaceType.Smooth
  467. Part65.brickColor = BrickColor.new("Dark stone grey")
  468. Part66.Name = "d24"
  469. Part66.Parent = mas
  470. Part66.CFrame = CFrame.new(-1.03000009, 0.48999998, -1.63912773e-07, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  471. Part66.Position = Vector3.new(-1.03000009, 0.48999998, -1.63912773e-07)
  472. Part66.Color = Color3.new(0.388235, 0.372549, 0.384314)
  473. Part66.Size = Vector3.new(0.159999982, 1, 0.600000381)
  474. Part66.BottomSurface = Enum.SurfaceType.Smooth
  475. Part66.BrickColor = BrickColor.new("Dark stone grey")
  476. Part66.CanCollide = false
  477. Part66.Material = Enum.Material.DiamondPlate
  478. Part66.TopSurface = Enum.SurfaceType.Smooth
  479. Part66.brickColor = BrickColor.new("Dark stone grey")
  480. Part66.Shape = Enum.PartType.Cylinder
  481. Part67.Name = "ray"
  482. Part67.Parent = mas
  483. Part67.CFrame = CFrame.new(1.16000128, 0.98999995, 2.23517418e-08, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  484. Part67.Position = Vector3.new(1.16000128, 0.98999995, 2.23517418e-08)
  485. Part67.Color = Color3.new(0.654902, 0.368627, 0.607843)
  486. Part67.Size = Vector3.new(5.22000217, 1, 0.520000458)
  487. Part67.BottomSurface = Enum.SurfaceType.Smooth
  488. Part67.BrickColor = BrickColor.new("Lilac")
  489. Part67.CanCollide = false
  490. Part67.Material = Enum.Material.Neon
  491. Part67.TopSurface = Enum.SurfaceType.Smooth
  492. Part67.brickColor = BrickColor.new("Lilac")
  493. Part67.Shape = Enum.PartType.Cylinder
  494. Part68.Name = "d26"
  495. Part68.Parent = mas
  496. Part68.CFrame = CFrame.new(2.52999949, 1.07482338, -0.0850001648, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  497. Part68.Position = Vector3.new(2.52999949, 1.07482338, -0.0850001648)
  498. Part68.Color = Color3.new(0.388235, 0.372549, 0.384314)
  499. Part68.Size = Vector3.new(0.159999982, 1, 0.990000427)
  500. Part68.BottomSurface = Enum.SurfaceType.Smooth
  501. Part68.BrickColor = BrickColor.new("Dark stone grey")
  502. Part68.CanCollide = false
  503. Part68.Material = Enum.Material.DiamondPlate
  504. Part68.TopSurface = Enum.SurfaceType.Smooth
  505. Part68.brickColor = BrickColor.new("Dark stone grey")
  506. Part68.Shape = Enum.PartType.Cylinder
  507. Part69.Name = "d8"
  508. Part69.Parent = mas
  509. Part69.CFrame = CFrame.new(3.62500095, 1, -0.0199998766, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  510. Part69.Position = Vector3.new(3.62500095, 1, -0.0199998766)
  511. Part69.Color = Color3.new(0.388235, 0.372549, 0.384314)
  512. Part69.Size = Vector3.new(0.50999999, 1.10000002, 0.840000272)
  513. Part69.BottomSurface = Enum.SurfaceType.Smooth
  514. Part69.BrickColor = BrickColor.new("Dark stone grey")
  515. Part69.CanCollide = false
  516. Part69.Material = Enum.Material.DiamondPlate
  517. Part69.TopSurface = Enum.SurfaceType.Smooth
  518. Part69.brickColor = BrickColor.new("Dark stone grey")
  519. Part69.Shape = Enum.PartType.Cylinder
  520. Part70.Name = "a7"
  521. Part70.Parent = mas
  522. Part70.CFrame = CFrame.new(0.920000017, 1, 0.00500012189, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  523. Part70.Position = Vector3.new(0.920000017, 1, 0.00500012189)
  524. Part70.Size = Vector3.new(4, 1, 0.730000257)
  525. Part70.BottomSurface = Enum.SurfaceType.Smooth
  526. Part70.CanCollide = false
  527. Part70.Material = Enum.Material.DiamondPlate
  528. Part70.TopSurface = Enum.SurfaceType.Smooth
  529. Part70.Shape = Enum.PartType.Cylinder
  530. Part71.Name = "d7"
  531. Part71.Parent = mas
  532. Part71.CFrame = CFrame.new(3.45999956, 1, -0.00999992527, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  533. Part71.Position = Vector3.new(3.45999956, 1, -0.00999992527)
  534. Part71.Color = Color3.new(0.388235, 0.372549, 0.384314)
  535. Part71.Size = Vector3.new(0.339999974, 1.10000002, 0.940000176)
  536. Part71.BottomSurface = Enum.SurfaceType.Smooth
  537. Part71.BrickColor = BrickColor.new("Dark stone grey")
  538. Part71.CanCollide = false
  539. Part71.Material = Enum.Material.DiamondPlate
  540. Part71.TopSurface = Enum.SurfaceType.Smooth
  541. Part71.brickColor = BrickColor.new("Dark stone grey")
  542. Part71.Shape = Enum.PartType.Cylinder
  543. Part72.Name = "d3"
  544. Part72.Parent = mas
  545. Part72.CFrame = CFrame.new(-0.0949997902, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  546. Part72.Position = Vector3.new(-0.0949997902, 1, 0)
  547. Part72.Color = Color3.new(0.388235, 0.372549, 0.384314)
  548. Part72.Size = Vector3.new(0.190000013, 1.10000002, 1.10000002)
  549. Part72.BottomSurface = Enum.SurfaceType.Smooth
  550. Part72.BrickColor = BrickColor.new("Dark stone grey")
  551. Part72.CanCollide = false
  552. Part72.Material = Enum.Material.DiamondPlate
  553. Part72.TopSurface = Enum.SurfaceType.Smooth
  554. Part72.brickColor = BrickColor.new("Dark stone grey")
  555. Part72.Shape = Enum.PartType.Cylinder
  556. Part73.Name = "d4"
  557. Part73.Parent = mas
  558. Part73.CFrame = CFrame.new(3.51756072, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  559. Part73.Position = Vector3.new(3.51756072, 1, 0)
  560. Part73.Color = Color3.new(0.388235, 0.372549, 0.384314)
  561. Part73.Size = Vector3.new(0.190000013, 1.10000002, 1.10000002)
  562. Part73.BottomSurface = Enum.SurfaceType.Smooth
  563. Part73.BrickColor = BrickColor.new("Dark stone grey")
  564. Part73.CanCollide = false
  565. Part73.Material = Enum.Material.DiamondPlate
  566. Part73.TopSurface = Enum.SurfaceType.Smooth
  567. Part73.brickColor = BrickColor.new("Dark stone grey")
  568. Part73.Shape = Enum.PartType.Cylinder
  569. Part74.Name = "d10"
  570. Part74.Parent = mas
  571. Part74.CFrame = CFrame.new(-1.03499973, 0.980000019, 0.00999992155, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  572. Part74.Position = Vector3.new(-1.03499973, 0.980000019, 0.00999992155)
  573. Part74.Color = Color3.new(0.388235, 0.372549, 0.384314)
  574. Part74.Size = Vector3.new(0.190000013, 1.10000002, 0.920000196)
  575. Part74.BottomSurface = Enum.SurfaceType.Smooth
  576. Part74.BrickColor = BrickColor.new("Dark stone grey")
  577. Part74.CanCollide = false
  578. Part74.Material = Enum.Material.DiamondPlate
  579. Part74.TopSurface = Enum.SurfaceType.Smooth
  580. Part74.brickColor = BrickColor.new("Dark stone grey")
  581. Part74.Shape = Enum.PartType.Cylinder
  582. Part75.Name = "d5"
  583. Part75.Parent = mas
  584. Part75.CFrame = CFrame.new(1.54000008, 1.03999996, -0.444999844, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  585. Part75.Position = Vector3.new(1.54000008, 1.03999996, -0.444999844)
  586. Part75.Color = Color3.new(0.654902, 0.368627, 0.607843)
  587. Part75.Size = Vector3.new(4.02000046, 1, 0.150000468)
  588. Part75.BottomSurface = Enum.SurfaceType.Smooth
  589. Part75.BrickColor = BrickColor.new("Lilac")
  590. Part75.CanCollide = false
  591. Part75.Material = Enum.Material.Neon
  592. Part75.TopSurface = Enum.SurfaceType.Smooth
  593. Part75.brickColor = BrickColor.new("Lilac")
  594. Part75.Shape = Enum.PartType.Cylinder
  595. Part76.Name = "d18"
  596. Part76.Parent = mas
  597. Part76.CFrame = CFrame.new(3.61553025, 1, -0.0250003319, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  598. Part76.Position = Vector3.new(3.61553025, 1, -0.0250003319)
  599. Part76.Color = Color3.new(0.831373, 0.564706, 0.741176)
  600. Part76.Size = Vector3.new(0.190000013, 1.10000002, 0.95000118)
  601. Part76.BottomSurface = Enum.SurfaceType.Smooth
  602. Part76.BrickColor = BrickColor.new("Sunrise")
  603. Part76.CanCollide = false
  604. Part76.Material = Enum.Material.Neon
  605. Part76.TopSurface = Enum.SurfaceType.Smooth
  606. Part76.brickColor = BrickColor.new("Sunrise")
  607. Part76.Shape = Enum.PartType.Cylinder
  608. Part77.Name = "d14"
  609. Part77.Parent = mas
  610. Part77.CFrame = CFrame.new(1.91999972, 0.48999998, -1.63912773e-07, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  611. Part77.Position = Vector3.new(1.91999972, 0.48999998, -1.63912773e-07)
  612. Part77.Color = Color3.new(0.388235, 0.372549, 0.384314)
  613. Part77.Size = Vector3.new(0.139999941, 1, 0.600000381)
  614. Part77.BottomSurface = Enum.SurfaceType.Smooth
  615. Part77.BrickColor = BrickColor.new("Dark stone grey")
  616. Part77.CanCollide = false
  617. Part77.Material = Enum.Material.DiamondPlate
  618. Part77.TopSurface = Enum.SurfaceType.Smooth
  619. Part77.brickColor = BrickColor.new("Dark stone grey")
  620. Part77.Shape = Enum.PartType.Cylinder
  621. Part78.Name = "a3"
  622. Part78.Parent = mas
  623. Part78.CFrame = CFrame.new(2.99571395, 0.249999955, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  624. Part78.Position = Vector3.new(2.99571395, 0.249999955, 0)
  625. Part78.Size = Vector3.new(0.431428641, 1.02285719, 0.302000105)
  626. Part78.BottomSurface = Enum.SurfaceType.Smooth
  627. Part78.CanCollide = false
  628. Part78.Material = Enum.Material.DiamondPlate
  629. Part78.TopSurface = Enum.SurfaceType.Smooth
  630. Part79.Name = "a2"
  631. Part79.Parent = mas
  632. Part79.CFrame = CFrame.new(2.99571395, 0.170000002, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  633. Part79.Position = Vector3.new(2.99571395, 0.170000002, 0)
  634. Part79.Color = Color3.new(0.388235, 0.372549, 0.384314)
  635. Part79.Size = Vector3.new(0.336514443, 0.759314477, 0.327886105)
  636. Part79.BottomSurface = Enum.SurfaceType.Smooth
  637. Part79.BrickColor = BrickColor.new("Dark stone grey")
  638. Part79.CanCollide = false
  639. Part79.Material = Enum.Material.DiamondPlate
  640. Part79.TopSurface = Enum.SurfaceType.Smooth
  641. Part79.brickColor = BrickColor.new("Dark stone grey")
  642. Part80.Name = "d17"
  643. Part80.Parent = mas
  644. Part80.CFrame = CFrame.new(1.54499984, 1.46000099, -0.125, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  645. Part80.Position = Vector3.new(1.54499984, 1.46000099, -0.125)
  646. Part80.Color = Color3.new(0.388235, 0.372549, 0.384314)
  647. Part80.Size = Vector3.new(4.02999926, 0.26000011, 0.0899998695)
  648. Part80.BottomSurface = Enum.SurfaceType.Smooth
  649. Part80.BrickColor = BrickColor.new("Dark stone grey")
  650. Part80.CanCollide = false
  651. Part80.Material = Enum.Material.DiamondPlate
  652. Part80.TopSurface = Enum.SurfaceType.Smooth
  653. Part80.brickColor = BrickColor.new("Dark stone grey")
  654. Part80.Shape = Enum.PartType.Cylinder
  655. Part81.Name = "d22"
  656. Part81.Parent = mas
  657. Part81.CFrame = CFrame.new(-0.750000477, 1.34000111, 0.0149999876, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  658. Part81.Position = Vector3.new(-0.750000477, 1.34000111, 0.0149999876)
  659. Part81.Color = Color3.new(0.388235, 0.372549, 0.384314)
  660. Part81.Size = Vector3.new(0.700000226, 0.26000011, 0.0899998695)
  661. Part81.BottomSurface = Enum.SurfaceType.Smooth
  662. Part81.BrickColor = BrickColor.new("Dark stone grey")
  663. Part81.CanCollide = false
  664. Part81.Material = Enum.Material.DiamondPlate
  665. Part81.TopSurface = Enum.SurfaceType.Smooth
  666. Part81.brickColor = BrickColor.new("Dark stone grey")
  667. Part81.Shape = Enum.PartType.Cylinder
  668. Part82.Name = "d12"
  669. Part82.Parent = mas
  670. Part82.Color = Color3.new(0.388235, 0.372549, 0.384314)
  671. Part82.Size = Vector3.new(0.25, 1, 0.600000381)
  672. Part82.BottomSurface = Enum.SurfaceType.Smooth
  673. Part82.BrickColor = BrickColor.new("Dark stone grey")
  674. Part82.CanCollide = false
  675. Part82.Material = Enum.Material.DiamondPlate
  676. Part82.TopSurface = Enum.SurfaceType.Smooth
  677. Part82.brickColor = BrickColor.new("Dark stone grey")
  678. Part82.Shape = Enum.PartType.Cylinder
  679. gripweld.Parent = char
  680. gripweld.Part0 = ra
  681. gripweld.Part1 = Part5
  682. gripweld.C0 = cfn(-2.4, -0.65, -0.65) * cfa(rad(-75), rad(180), rad(-14))
  683. for i,v in pairs(mas:GetChildren()) do
  684.     pcall(function() v:MakeJoints() end)
  685. end
  686. for i,v in pairs(cors) do
  687.     spawn(function()
  688.         pcall(v)
  689.     end)
  690. end
  691.  
  692. ArtificialHB = Instance.new('BindableEvent', script)
  693. ArtificialHB.Name = 'Heartbeat'
  694. script:WaitForChild('Heartbeat')
  695.  
  696. frame = 1 / 60
  697. tf = 0
  698. allowframeloss = false
  699. tossremainder = false
  700. lastframe = tick()
  701. script.Heartbeat:Fire()
  702.  
  703. game:GetService('RunService').Heartbeat:connect(function(s, p)
  704.     tf = tf + s
  705.     if tf >= frame then
  706.         if allowframeloss then
  707.             script.Heartbeat:Fire()
  708.             lastframe = tick()
  709.         else
  710.             for i = 1, math.floor(tf / frame) do
  711.                 script.Heartbeat:Fire()
  712.             end
  713.             lastframe = tick()
  714.         end
  715.         if tossremainder then
  716.             tf = 0
  717.         else
  718.             tf = tf - frame * math.floor(tf / frame)
  719.         end
  720.     end
  721. end)
  722.  
  723. function swait(t)
  724.     if t == 0 or t == nil then
  725.         script.Heartbeat.Event:Wait()
  726.     else
  727.         for i = 0, t do
  728.             script.Heartbeat.Event:Wait()
  729.         end
  730.     end
  731. end
  732.  
  733. function sound(id, parent, volume, pitch, timepos, name)
  734.     local s = Instance.new('Sound')
  735.     s.Parent = parent
  736.     s.SoundId = 'rbxassetid://'..id
  737.     s.Volume = volume
  738.     s.Name = name
  739.     s.PlaybackSpeed = pitch
  740.     s.TimePosition = timepos
  741.     s:Play()
  742.     game.Debris:AddItem(s, 5)
  743. end
  744.  
  745. function camshake(duration, intensity)
  746.     coroutine.wrap(function()
  747.         for i = 1, duration do
  748.             hum.CameraOffset = hum.CameraOffset:lerp(v3(rand(-1, 1), rand(-1, 1), rand(-1, 1)), 0.1 * intensity)
  749.             swait()
  750.         end
  751.         hum.CameraOffset = v3(0, 0, 0)
  752.     end)()
  753. end
  754.  
  755. function raycast(pos, direction, range, ignoredecendants)
  756.     return workspace:FindPartOnRay(Ray.new(pos, direction.unit * range), ignoredecendants)
  757. end
  758.  
  759. function shoot()
  760.     attack = true
  761.     cananim = false
  762.     local bg = Instance.new('BodyGyro', hd)
  763.     bg.MaxTorque = v3(0, 9000, 0)
  764.     bg.D = 175
  765.     bg.P = 20000
  766.     hum.WalkSpeed = 0
  767.     hum.JumpPower = 0
  768.     for i = 1, 20 do
  769.         bg.CFrame = cfn(hd.Position, mouse.Hit.p)
  770.         gripweld.C0 = gripweld.C0:lerp(cfn(-2.2, -1.3, -0.65) * cfa(rad(-75), rad(160), rad(-14)), 0.15)
  771.         TORSOLERP.C0 = TORSOLERP.C0:lerp(cfn(0, 0, 0) * cfor(rad(0), rad(-70), rad(0)), 0.15)
  772.         HEADLERP.C0 = HEADLERP.C0:lerp(cfn(0, 1.5, 0) * cfor(rad(0), rad(80), rad(0)), 0.15)
  773.         RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(cfn(1.354, 0.271, -1) * cfor(rad(76), rad(-60), rad(-76)), 0.15)
  774.         LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(cfn(-1.65, 0.511, -1) * cfor(rad(80), rad(-20), rad(-50)), 0.15)
  775.         RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(cfn(0.423, -2.055, 0.726) * cfor(rad(-10), rad(0), rad(10)), 0.15)
  776.         LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(cfn(-0.423, -2.055, -0.526) * cfor(rad(10), rad(0), rad(-10)), 0.15)
  777.         swait()
  778.     end
  779.     camshake(20, 5)
  780.     local ray = Ray.new(ra.CFrame.p, (mouse.Hit.p - ra.CFrame.p).unit * 999.999)
  781.     local part, pos = workspace:FindPartOnRay(ray, char, false, true)
  782.     local beam = Instance.new('Part', effects)
  783.     local effect = Instance.new('Part', effects)
  784.     local explosion1 = Instance.new('Part', effects)
  785.     local explosion2 = Instance.new('Part', effects)
  786.     local fakeexplosion = Instance.new('Part', effects)
  787.     sound(131179973, Part67, 5, 1.25, 0, '')
  788.     fakeexplosion.CanCollide = false
  789.     fakeexplosion.Anchored = false
  790.     fakeexplosion.Transparency = 1
  791.     fakeexplosion.Shape = 'Ball'
  792.     explosion2.CanCollide = false
  793.     explosion2.Anchored = true
  794.     explosion2.BrickColor = BrickColor.new('Sunrise')
  795.     explosion2.Material = 'Neon'
  796.     explosion2.Shape = 'Ball'
  797.     explosion2.Size = v3(0, 0, 0)
  798.     explosion1.CanCollide = false
  799.     explosion1.Anchored = true
  800.     explosion1.Anchored = true
  801.     explosion1.BrickColor = BrickColor.new('Sunrise')
  802.     explosion1.Material = 'Neon'
  803.     explosion1.Shape = 'Ball'
  804.     explosion1.Size = v3(0, 0, 0)
  805.     effect.CanCollide = false
  806.     effect.BrickColor = BrickColor.new('Sunrise')
  807.     effect.Anchored = true
  808.     effect.Material = 'Neon'
  809.     effect.Shape = 'Block'
  810.     effect.Size = v3(0, 0, 0)
  811.     beam.CanCollide = false
  812.     beam.Anchored = true
  813.     beam.BrickColor = BrickColor.new('Sunrise')
  814.     beam.Material = 'Neon'
  815.     beam.Shape = 'Cylinder'
  816.     explosion1.CFrame = cfn(mouse.Hit.p)
  817.     explosion2.CFrame = cfn(mouse.Hit.p)
  818.     fakeexplosion.CFrame = cfn(mouse.Hit.p)
  819.     fakeexplosion.Touched:connect(function(hit)
  820.         if hit.Parent then
  821.             if not hit:IsDescendantOf(char) and not hit:IsDescendantOf(mas) and hit ~= bases then
  822.                     local bv = Instance.new('BodyVelocity', hit)
  823.                     bv.MaxForce = v3(math.huge, math.huge, math.huge)
  824.                     bv.Velocity = cfn(fakeexplosion.Position, hit.Position).lookVector*50
  825.                     hit:BreakJoints()
  826.                     hit.BrickColor = BrickColor.new('Sunrise')
  827.                     hit.Material = 'Neon'
  828.                     coroutine.wrap(function()
  829.                         for i = 1, 1000 do
  830.                             hit.Transparency = hit.Transparency + 0.0030
  831.                             hit.Size = hit.Size:lerp(v3(0, 0, 0), 0.0030)
  832.                             if hit.Transparency >= 1 then
  833.                                 hit:Destroy()
  834.                             end
  835.                             swait()
  836.                         end
  837.                     end)()
  838.                     hit.Anchored = false
  839.                     hit.CanCollide = false
  840.                     --hit.CFrame = hit.CFrame:lerp(CFrame.fromEulerAnglesXYZ(rand(-30, 30), rand(-30, 30), rand(-30, 30)), 0.1)
  841.                     game.Debris:AddItem(bv, 0.1)
  842.             end
  843.         end
  844.     end)
  845.     coroutine.wrap(function()
  846.         for i = 1, 1000 do
  847.             explosion1.Size = explosion1.Size:lerp(v3(55, 55, 55), 0.010)
  848.             explosion1.Transparency = explosion1.Transparency + 0.010
  849.             fakeexplosion.CFrame = explosion1.CFrame
  850.             fakeexplosion.Size = fakeexplosion.Size:lerp(v3(55, 55, 55), 0.010)
  851.             explosion2.Size = explosion2.Size:lerp(v3(55, 55, 55), 0.0080)
  852.             explosion2.Transparency = explosion2.Transparency + 0.0080
  853.             effect.Size = effect.Size:Lerp(v3(5, 5, 5), 0.15)
  854.             beam.Transparency = beam.Transparency + 0.13
  855.             effect.Transparency = effect.Transparency + 0.13
  856.             if explosion1.Transparency >= 1 then
  857.                 explosion1:Destroy()
  858.                 fakeexplosion:Destroy()
  859.             end
  860.             if explosion2.Transparency >= 1 then
  861.                 explosion2:Destroy()
  862.             end
  863.             if effect.Transparency >= 1 then
  864.                 effect:Destroy()
  865.             end
  866.             if beam.Transparency >= 1 then
  867.                 beam:Destroy()
  868.             end
  869.             swait()
  870.         end
  871.     end)()
  872.     for i = 1, 15 do
  873.         local dist = (ra.CFrame.p - pos).magnitude
  874.         effect.CFrame = Part67.CFrame * cfn(3.5, -0.1, 0) * CFrame.fromEulerAnglesXYZ(rand(0, 360), rand(0, 360), rand(0, 360))
  875.         beam.CFrame = cfn(Part67.CFrame.p, pos) * cfn(0, 1, -3 - dist/2) * cfa(rad(0), rad(90), rad(0))
  876.         beam.Size = v3(dist, 0.5, 0.5)
  877.         TORSOLERP.C0 = TORSOLERP.C0:lerp(cfn(0, 0.3, 0.65) * cfor(rad(0), rad(-70), rad(-30)), 0.15)
  878.         swait()
  879.     end
  880.     coroutine.wrap(function()
  881.         for i = 1, 100 do
  882.             gripweld.C0 = gripweld.C0:lerp(cfn(-2.4, -0.65, -0.65) * cfa(rad(-75), rad(180), rad(-14)), 0.15)
  883.         swait()
  884.         end
  885.     end)()
  886.     if onrun then
  887.         hum.WalkSpeed = 25
  888.     else
  889.         hum.WalkSpeed = 16
  890.     end
  891.     hum.JumpPower = 50
  892.     bg:Destroy()
  893.     cananim = true
  894.     wait(1.5)
  895.     attack = false
  896. end
  897.  
  898. function chargedshoot()
  899.     attack = true
  900.     cananim = false
  901.     local bg = Instance.new('BodyGyro', hd)
  902.     bg.MaxTorque = v3(0, 9000, 0)
  903.     bg.D = 175
  904.     bg.P = 20000
  905.     hum.WalkSpeed = 0
  906.     hum.JumpPower = 0
  907.     for i = 1, 200 do
  908.         camshake(10, 0.4)
  909.         bg.CFrame = cfn(hd.Position, mouse.Hit.p)
  910.         gripweld.C0 = gripweld.C0:lerp(cfn(-2.2, -1.3, -0.65) * cfa(rad(-75 + 40 * sin(sine/1)), rad(160 + 10 * sin(sine/1)), rad(-14)), 0.15)
  911.         TORSOLERP.C0 = TORSOLERP.C0:lerp(cfn(0, 0, 0) * cfor(rad(0), rad(-70), rad(0)), 0.15)
  912.         HEADLERP.C0 = HEADLERP.C0:lerp(cfn(0, 1.5, 0) * cfor(rad(0), rad(80), rad(0)), 0.15)
  913.         RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(cfn(1.354, 0.271, -1) * cfor(rad(76), rad(-60), rad(-76)), 0.15)
  914.         LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(cfn(-1.65, 0.511, -1) * cfor(rad(80), rad(-20), rad(-50)), 0.15)
  915.         RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(cfn(0.423, -2.055, 0.726) * cfor(rad(-10), rad(0), rad(10)), 0.15)
  916.         LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(cfn(-0.423, -2.055, -0.526) * cfor(rad(10), rad(0), rad(-10)), 0.15)
  917.         swait()
  918.     end
  919.     camshake(10, 10)
  920.     local effect2 = Instance.new('Part', effects)
  921.     local ray = Ray.new(ra.CFrame.p, (mouse.Hit.p - ra.CFrame.p).unit * 300)
  922.     local part, pos = workspace:FindPartOnRay(ray, char, false, true)
  923.     local beam = Instance.new('Part', effects)
  924.     local effect = Instance.new('Part', effects)
  925.     local explosion1 = Instance.new('Part', effects)
  926.     local explosion2 = Instance.new('Part', effects)
  927.     local fakeexplosion = Instance.new('Part', effects)
  928.     sound(131179973, Part67, 5, 1, 0, '')
  929.     effect2.CanCollide = false
  930.     effect2.BrickColor = BrickColor.new('Sunrise')
  931.     effect2.Anchored = true
  932.     effect2.Material = 'Neon'
  933.     effect2.Shape = 'Block'
  934.     effect2.Size = v3(0, 0, 0)
  935.     fakeexplosion.CanCollide = false
  936.     fakeexplosion.Anchored = false
  937.     fakeexplosion.Transparency = 1
  938.     fakeexplosion.Shape = 'Ball'
  939.     explosion2.CanCollide = false
  940.     explosion2.Anchored = true
  941.     explosion2.BrickColor = BrickColor.new('Sunrise')
  942.     explosion2.Material = 'Neon'
  943.     explosion2.Shape = 'Ball'
  944.     explosion2.Size = v3(0, 0, 0)
  945.     explosion1.CanCollide = false
  946.     explosion1.Anchored = true
  947.     explosion1.Anchored = true
  948.     explosion1.BrickColor = BrickColor.new('Sunrise')
  949.     explosion1.Material = 'Neon'
  950.     explosion1.Shape = 'Ball'
  951.     explosion1.Size = v3(0, 0, 0)
  952.     effect.CanCollide = false
  953.     effect.BrickColor = BrickColor.new('Sunrise')
  954.     effect.Anchored = true
  955.     effect.Material = 'Neon'
  956.     effect.Shape = 'Block'
  957.     effect.Size = v3(0, 0, 0)
  958.     beam.CanCollide = false
  959.     beam.Anchored = true
  960.     beam.BrickColor = BrickColor.new('Sunrise')
  961.     beam.Material = 'Neon'
  962.     beam.Shape = 'Cylinder'
  963.     explosion1.CFrame = cfn(mouse.Hit.p)
  964.     explosion2.CFrame = cfn(mouse.Hit.p)
  965.     fakeexplosion.CFrame = cfn(mouse.Hit.p)
  966.     fakeexplosion.Touched:connect(function(hit)
  967.         if hit.Parent then
  968.             if not hit:IsDescendantOf(char) and not hit:IsDescendantOf(mas) and hit ~= bases then
  969.                     local bv = Instance.new('BodyVelocity', hit)
  970.                     bv.MaxForce = v3(math.huge, math.huge, math.huge)
  971.                     bv.Velocity = cfn(fakeexplosion.Position, hit.Position).lookVector*100
  972.                     hit:BreakJoints()
  973.                     hit.BrickColor = BrickColor.new('Sunrise')
  974.                     hit.Material = 'Neon'
  975.                     coroutine.wrap(function()
  976.                         for i = 1, 1000 do
  977.                             hit.Transparency = hit.Transparency + 0.0030
  978.                             hit.Size = hit.Size:lerp(v3(0, 0, 0), 0.0030)
  979.                             if hit.Transparency >= 1 then
  980.                                 hit:Destroy()
  981.                             end
  982.                             swait()
  983.                         end
  984.                     end)()
  985.                     hit.Anchored = false
  986.                     hit.CanCollide = true
  987.                     --hit.CFrame = hit.CFrame:lerp(CFrame.fromEulerAnglesXYZ(rand(-30, 30), rand(-30, 30), rand(-30, 30)), 0.1)
  988.                     game.Debris:AddItem(bv, 0.1)
  989.             end
  990.         end
  991.     end)
  992.     coroutine.wrap(function()
  993.         effect2.CFrame = Part67.CFrame * cfn(8, -0.1, 0) * CFrame.fromEulerAnglesXYZ(rand(0, 360), rand(0, 360), rand(0, 360))
  994.         for i = 1, 1000 do
  995.             effect2.Size = effect2.Size:lerp(v3(25, 25, 25), 0.01)
  996.             effect2.Transparency = effect2.Transparency + 0.01
  997.             if effect2.Transparency >= 1 then
  998.                 effect2:Destroy()
  999.             end
  1000.             swait()
  1001.         end
  1002.     end)()
  1003.     coroutine.wrap(function()
  1004.         for i = 1, 1000 do
  1005.             local dist = (ra.CFrame.p - pos).magnitude
  1006.             explosion1.Size = explosion1.Size:lerp(v3(250, 250, 250), 0.0070)
  1007.             explosion1.Transparency = explosion1.Transparency + 0.0070
  1008.             explosion2.Size = explosion2.Size:lerp(v3(250, 250, 250), 0.0050)
  1009.             explosion2.Transparency = explosion2.Transparency + 0.0050
  1010.             fakeexplosion.Size = fakeexplosion.Size:lerp(v3(250, 250, 250), 0.0070)
  1011.             fakeexplosion.CFrame = explosion1.CFrame
  1012.             beam.Size = beam.size:lerp(v3(dist, 30, 30), 0.01)
  1013.             beam.Transparency = beam.Transparency + 0.01
  1014.             if explosion1.Transparency >= 1 then
  1015.                 explosion1:Destroy()
  1016.                 fakeexplosion:Destroy()
  1017.             end
  1018.             if explosion2.Transparency >= 1 then
  1019.                 explosion2:Destroy()
  1020.             end
  1021.             if beam.Transparency >= 1 then
  1022.                 beam:Destroy()
  1023.             end
  1024.             swait()
  1025.         end
  1026.     end)()
  1027.     for i = 1, 15 do
  1028.         local dist = (ra.CFrame.p - pos).magnitude
  1029.         beam.Size = v3(dist, 0, 0)
  1030.         beam.CFrame = cfn(Part67.CFrame.p, pos) * cfn(0, 1, -8 - dist/2) * cfa(rad(0), rad(90), rad(0))
  1031.         effect.CFrame = Part67.CFrame * cfn(3.5, -0.3, 0) * CFrame.fromEulerAnglesXYZ(rand(0, 360), rand(0, 360), rand(0, 360))
  1032.         effect.Size = effect.Size:Lerp(v3(5, 5, 5), 0.15)
  1033.         effect.Transparency = effect.Transparency + 0.1
  1034.         TORSOLERP.C0 = TORSOLERP.C0:lerp(cfn(0, 0.3, 0.65) * cfor(rad(0), rad(-70), rad(-30)), 0.15)
  1035.         if effect.Transparency >= 1 then
  1036.             effect:Destroy()
  1037.         end
  1038.         swait()
  1039.     end
  1040.     coroutine.wrap(function()
  1041.         for i = 1, 100 do
  1042.             gripweld.C0 = gripweld.C0:lerp(cfn(-2.4, -0.65, -0.65) * cfa(rad(-75), rad(180), rad(-14)), 0.15)
  1043.         swait()
  1044.         end
  1045.     end)()
  1046.     if onrun then
  1047.         hum.WalkSpeed = 25
  1048.     else
  1049.         hum.WalkSpeed = 16
  1050.     end
  1051.     hum.JumpPower = 50
  1052.     bg:Destroy()
  1053.     cananim = true
  1054.     wait(5)
  1055.     attack = false
  1056. end
  1057.  
  1058. mouse.Button1Down:connect(function()
  1059.     if attack == false and cananim then
  1060.         shoot()
  1061.     end
  1062. end)
  1063.  
  1064. mouse.KeyDown:connect(function(key)
  1065.     key = key:lower()
  1066.     if key == 'q' and onrun == false and attack == false then
  1067.         onrun = true
  1068.         hum.WalkSpeed = 25
  1069.     elseif key == 'q' and onrun and attack == false then
  1070.         onrun = false
  1071.         hum.WalkSpeed = 16
  1072.     end
  1073.     if key == 'm' then
  1074.         if sicko.IsPlaying then
  1075.         sicko:Pause()
  1076.     elseif sicko.IsPaused then
  1077.         sicko:Resume()
  1078.         end
  1079.     end
  1080.     if key == 'f' and attack == false and cananim then
  1081.         chargedshoot()
  1082.     end
  1083. end)
  1084.  
  1085. while true do
  1086.     sine = sine + change
  1087.     local tsvel = (root.Velocity * v3(1, 0, 1)).magnitude
  1088.     local hitfloor = raycast(root.Position, (cfn(root.Position, root.Position + v3(0, -1, 0))).lookVector, 4 * 1, char)
  1089.     if root.Velocity.y > 1 and hitfloor == nil and cananim then
  1090.         change = 1
  1091.         TORSOLERP.C0 = TORSOLERP.C0:lerp(cfn(0, 0.3, 0.3) * cfa(rad(20), rad(0), rad(0)), 0.070)
  1092.         HEADLERP.C0 = HEADLERP.C0:lerp(cfn(0, 1.5, 0) * cfa(rad(0), rad(0), rad(0)), 0.1)
  1093.         RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(cfn(1.516, 0.216, -0.728) * cfa(rad(71.8), rad(0.2), rad(-0.7)), 0.070)
  1094.         LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(cfn(-1.499, -0.042, -0.75) * cfa(rad(60.2), rad(10 * sin(sine/40)), rad(4.5)), 0.070)
  1095.         RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(cfn(0.604, -1.793, 0.204) * cfa(rad(-19.4), rad(-7), rad(10.2)), 0.070)
  1096.         LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(cfn(-0.574, -1.811, 0.046) * cfa(rad(-9.8), rad(-1.8), rad(0.04)), 0.070)
  1097.     elseif root.Velocity.y < -1 and hitfloor == nil and cananim then
  1098.         change = 1
  1099.         TORSOLERP.C0 = TORSOLERP.C0:lerp(cfn(0, 0.3, 0) * cfa(rad(-20), rad(0), rad(0)), 0.070)
  1100.         HEADLERP.C0 = HEADLERP.C0:lerp(cfn(0, 1.5, 0) * cfa(rad(0), rad(0), rad(0)), 0.1)
  1101.         RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(cfn(1.516, 0.216, -0.728) * cfa(rad(71.8), rad(0.2), rad(-0.7)), 0.070)
  1102.         LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(cfn(-1.499, -0.042, -0.75) * cfa(rad(60.2), rad(10 * sin(sine/40)), rad(4.5)), 0.070)
  1103.         RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(cfn(0.622, -1.726, 0.269) * cfa(rad(9.56), rad(5.2), rad(9.82)), 0.070)
  1104.         LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(cfn(-0.588, -1.654, 0.775) * cfa(rad(-20), rad(-1.6), rad(0.7)), 0.070)
  1105.     elseif tsvel < 2 and hitfloor ~= nil and cananim then
  1106.         change = 1
  1107.         TORSOLERP.C0 = TORSOLERP.C0:lerp(cfn(0, 0.1 * sin(sine/40), 0) * cfa(rad(3 * sin(sine/40)), rad(0), rad(0)), 0.1)
  1108.         HEADLERP.C0 = HEADLERP.C0:lerp(cfn(-0, 1.5, 0) * cfa(rad(-3 * sin(sine/40)), rad(0), rad(-0)), 0.1)
  1109.         RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(cfn(1.516, 0.216, -0.728) * cfa(rad(71.8), rad(0.2), rad(-0.7)), 0.1)
  1110.         LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(cfn(-1.499, -0.042, -0.75) * cfa(rad(60.2), rad(10), rad(4.5)), 0.1)
  1111.         RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(cfn(0.687, -2.073, 0) * cfa(rad(0), rad(0), rad(10.3)), 0.1)
  1112.         LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(cfn(-0.614, -2.049, 0) * cfa(rad(0), rad(0), rad(-6.37)), 0.1)
  1113.     elseif tsvel < 20 and hitfloor ~= nil and cananim then
  1114.         change = 1
  1115.         TORSOLERP.C0 = TORSOLERP.C0:lerp(cfn(0 - root.RotVelocity.Y/50, 0.1 + sin(sine/3), 0) * cfa(rad(5 * -sin(sine/6)), rad(0), rad(0) + root.RotVelocity.Y/50), 0.1)
  1116.         HEADLERP.C0 = HEADLERP.C0:lerp(cfn(0, 1.5, 0) * cfa(rad(-5 * sin(sine/6)), rad(0) + hd.RotVelocity.Y/30, rad(0)), 0.1)
  1117.         RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(cfn(1.516, 0.216, -0.728) * cfa(rad(71.8), rad(0.2), rad(-0.7)), 0.1)
  1118.         LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(cfn(-1.499, -0.042, -0.75) * cfa(rad(60.2), rad(4.48), rad(4.5)), 0.1)
  1119.         RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(cfn(0.5, -2, -1.45 * sin(sine/6)) * cfa(rad(90 * sin(sine/6)), rad(0), rad(0)), 0.13)
  1120.         LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(cfn(-0.5, -2, 1.45 * sin(sine/6)) * cfa(rad(-90 * sin(sine/6)), rad(0), rad(0)), 0.13)
  1121.     elseif tsvel > 20 and hitfloor ~= nil and cananim then
  1122.         change = 1
  1123.         TORSOLERP.C0 = TORSOLERP.C0:lerp(cfn(0 - root.RotVelocity.Y/50, 0.1 + sin(sine/3), -0.3) * cfa(rad(-10 + 5 * -sin(sine/6)), rad(0), rad(0) + root.RotVelocity.Y/50), 0.13)
  1124.         HEADLERP.C0 = HEADLERP.C0:lerp(cfn(0, 1.5, 0) * cfa(rad(-5 * sin(sine/6)), rad(0) + hd.RotVelocity.Y/30, rad(0)), 0.13)
  1125.         RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(cfn(1.516, 0.216, -0.728) * cfa(rad(71.8), rad(0.2), rad(-0.7)), 0.13)
  1126.         LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(cfn(-1.499, -0.042, -0.75) * cfa(rad(60.2), rad(4.48), rad(4.5)), 0.13)
  1127.         RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(cfn(0.5, -2, -1.45 * sin(sine/6)) * cfa(rad(90 * sin(sine/6)), rad(0), rad(0)), 0.15)
  1128.         LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(cfn(-0.5, -2, 1.45 * sin(sine/6)) * cfa(rad(-90 * sin(sine/6)), rad(0), rad(0)), 0.15)
  1129.     end
  1130.     swait()
  1131. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement