Advertisement
heyoooooooooo

Untitled

Jan 26th, 2020
114
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 45.51 KB | None | 0 0
  1. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  2. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  3. do
  4. print("FE Compatibility code by Mokiros")
  5. script.Parent = Player.Character
  6.  
  7. --RemoteEvent for communicating
  8. local Event = Instance.new("RemoteEvent")
  9. Event.Name = "UserInput_Event"
  10.  
  11. --Fake event to make stuff like Mouse.KeyDown work
  12. local function fakeEvent()
  13. local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
  14. t.connect = t.Connect
  15. return t
  16. end
  17.  
  18. --Creating fake input objects with fake variables
  19. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  20. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  21. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  22. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  23. end}
  24. --Merged 2 functions into one by checking amount of arguments
  25. CAS.UnbindAction = CAS.BindAction
  26.  
  27. --This function will trigger the events that have been :Connect()'ed
  28. local function te(self,ev,...)
  29. local t = m[ev]
  30. if t and t._fakeEvent and t.Function then
  31. t.Function(...)
  32. end
  33. end
  34. m.TrigEvent = te
  35. UIS.TrigEvent = te
  36.  
  37. Event.OnServerEvent:Connect(function(plr,io)
  38. if plr~=Player then return end
  39. if io.isMouse then
  40. m.Target = io.Target
  41. m.Hit = io.Hit
  42. else
  43. local b = io.UserInputState == Enum.UserInputState.Begin
  44. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  45. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  46. end
  47. for _,t in pairs(CAS.Actions) do
  48. for _,k in pairs(t.Keys) do
  49. if k==io.KeyCode then
  50. t.Function(t.Name,io.UserInputState,io)
  51. end
  52. end
  53. end
  54. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  55. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  56. end
  57. end)
  58. Event.Parent = NLS([==[
  59. local Player = game:GetService("Players").LocalPlayer
  60. local Event = script:WaitForChild("UserInput_Event")
  61.  
  62. local UIS = game:GetService("UserInputService")
  63. local input = function(io,a)
  64. if a then return end
  65. --Since InputObject is a client-side instance, we create and pass table instead
  66. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
  67. end
  68. UIS.InputBegan:Connect(input)
  69. UIS.InputEnded:Connect(input)
  70.  
  71. local mouse = Player:GetMouse()
  72. local h,t
  73. --Give the server mouse data 30 times every second, but only if the values changed
  74. --If player is not moving their mouse, client won't fire events
  75. while wait(1/30) do
  76. if h~=mouse.Hit or t~=mouse.Target then
  77. h,t=mouse.Hit,mouse.Target
  78. Event:FireServer({ismouse=true,Target=t,Hit=h})
  79. end
  80. end]==],Player.Character)
  81. mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
  82. end
  83. CV="White"
  84.  
  85. p = game.Players.LocalPlayer
  86. char = p.Character
  87. local txt = Instance.new("BillboardGui", char)
  88. txt.Adornee = char .Head
  89. txt.Name = "_status"
  90. txt.Size = UDim2.new(2, 0, 1.2, 0)
  91. txt.StudsOffset = Vector3.new(-9, 8, 0)
  92. local text = Instance.new("TextLabel", txt)
  93. text.Size = UDim2.new(10, 0, 7, 0)
  94. text.FontSize = "Size24"
  95. text.TextScaled = true
  96. text.TextTransparency = 0
  97. text.BackgroundTransparency = 1
  98. text.TextTransparency = 0
  99. text.TextStrokeTransparency = 1
  100. text.Font = "Arcade"
  101. text.TextStrokeColor3 = Color3.new(0,0,255)
  102.  
  103. v=Instance.new("Part")
  104. v.Name = "ColorBrick"
  105. v.Parent=p.Character
  106. v.FormFactor="Symmetric"
  107. v.Anchored=true
  108. v.CanCollide=false
  109. v.BottomSurface="Smooth"
  110. v.TopSurface="Smooth"
  111. v.Size=Vector3.new(10,5,3)
  112. v.Transparency=1
  113. v.CFrame=char.Torso.CFrame
  114. v.BrickColor=BrickColor.new(CV)
  115. v.Transparency=1
  116. text.TextColor3 = Color3.new(255,255,0)
  117. v.Shape="Block"
  118. text.Text = "Golden God"
  119. wait(1 / 60)
  120. Effects = { }
  121. local Player = owner
  122. local Character = Player.Character
  123. local Humanoid = Character.Humanoid
  124. local mouse = Player:GetMouse()
  125. local m = Instance.new('Model', Character)
  126. m.Name = "WeaponModel"
  127. local LeftArm = Character["Left Arm"]
  128. local RightArm = Character["Right Arm"]
  129. local LeftLeg = Character["Left Leg"]
  130. local RightLeg = Character["Right Leg"]
  131. local Head = Character.Head
  132. local Torso = Character.Torso
  133. local cam = game.Workspace.CurrentCamera
  134. local RootPart = Character.HumanoidRootPart
  135. local RootJoint = RootPart.RootJoint
  136. local equipped = false
  137. local attack = false
  138. local Anim = 'Idle'
  139. local idle = 0
  140. local attacktype = 1
  141. local Torsovelocity = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude
  142. local velocity = RootPart.Velocity.y
  143. local sine = 0
  144. local change = 1
  145. local grabbed = false
  146. local cn = CFrame.new
  147. local mr = math.rad
  148. local angles = CFrame.Angles
  149. local ud = UDim2.new
  150. local c3 = Color3.new
  151. Instance.new("ForceField", game.Players.LocalPlayer.Character)
  152. local s = Instance.new("Sound",Character)
  153. s.Name = "BGMusic"
  154. s.SoundId = "rbxassetid://255341408"
  155. s.Pitch = 1
  156. s.Volume = 0.55
  157. s.Looped = true
  158. s.archivable = false
  159. wait(0.1)
  160. s:play()
  161.  
  162. Humanoid.Animator.Parent = nil
  163. Character.Animate.Parent = nil
  164.  
  165. local newMotor = function(part0, part1, c0, c1)
  166. local w = Instance.new('Motor', part0)
  167. w.Part0 = part0
  168. w.Part1 = part1
  169. w.C0 = c0
  170. w.C1 = c1
  171. return w
  172. end
  173.  
  174. function clerp(a, b, t)
  175. return a:lerp(b, t)
  176. end
  177.  
  178. RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14)
  179. NeckCF = CFrame.new(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  180.  
  181. local RW = newMotor(Torso, RightArm, CFrame.new(1.5, 0, 0), CFrame.new(0, 0, 0))
  182. local LW = newMotor(Torso, LeftArm, CFrame.new(-1.5, 0, 0), CFrame.new(0, 0, 0))
  183. local RH = newMotor(Torso, RightLeg, CFrame.new(.5, -2, 0), CFrame.new(0, 0, 0))
  184. local LH = newMotor(Torso, LeftLeg, CFrame.new(-.5, -2, 0), CFrame.new(0, 0, 0))
  185. RootJoint.C1 = CFrame.new(0, 0, 0)
  186. RootJoint.C0 = CFrame.new(0, 0, 0)
  187. Torso.Neck.C1 = CFrame.new(0, 0, 0)
  188. Torso.Neck.C0 = CFrame.new(0, 1.5, 0)
  189.  
  190. local rarmc1 = RW.C1
  191. local larmc1 = LW.C1
  192. local rlegc1 = RH.C1
  193. local llegc1 = LH.C1
  194.  
  195. local resetc1 = false
  196.  
  197. function PlayAnimationFromTable(table, speed, bool)
  198. RootJoint.C0 = clerp(RootJoint.C0, table[1], speed)
  199. Torso.Neck.C0 = clerp(Torso.Neck.C0, table[2], speed)
  200. RW.C0 = clerp(RW.C0, table[3], speed)
  201. LW.C0 = clerp(LW.C0, table[4], speed)
  202. RH.C0 = clerp(RH.C0, table[5], speed)
  203. LH.C0 = clerp(LH.C0, table[6], speed)
  204. if bool == true then
  205. if resetc1 == false then
  206. resetc1 = true
  207. RootJoint.C1 = RootJoint.C1
  208. Torso.Neck.C1 = Torso.Neck.C1
  209. RW.C1 = rarmc1
  210. LW.C1 = larmc1
  211. RH.C1 = rlegc1
  212. LH.C1 = llegc1
  213. end
  214. end
  215. end
  216.  
  217. Char = char
  218.  
  219. --[[Credits to SazErenos for his Artificial Heartbeat Also this was Edited by UilmateGate]]--
  220.  
  221. ArtificialHB = Instance.new("BindableEvent", script)
  222. ArtificialHB.Name = "Heartbeat"
  223.  
  224. script:WaitForChild("Heartbeat")
  225.  
  226. frame = 1 / 30
  227. tf = 0
  228. allowframeloss = false
  229. tossremainder = false
  230. lastframe = tick()
  231. script.Heartbeat:Fire()
  232.  
  233. game:GetService("RunService").Heartbeat:connect(function(s, p)
  234. tf = tf + s
  235. if tf >= frame then
  236. if allowframeloss then
  237. script.Heartbeat:Fire()
  238. lastframe = tick()
  239. else
  240. for i = 1, math.floor(tf / frame) do
  241. script.Heartbeat:Fire()
  242. end
  243. lastframe = tick()
  244. end
  245. if tossremainder then
  246. tf = 0
  247. else
  248. tf = tf - frame * math.floor(tf / frame)
  249. end
  250. end
  251. end)
  252.  
  253. function swait(num)
  254. if num == 0 or num == nil then
  255. ArtificialHB.Event:wait()
  256. else
  257. for i = 0, num do
  258. ArtificialHB.Event:wait()
  259. end
  260. end
  261. end
  262.  
  263. local RbxUtility = LoadLibrary("RbxUtility")
  264. local Create = RbxUtility.Create
  265.  
  266. function RemoveOutlines(part)
  267. part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10
  268. end
  269.  
  270. CFuncs = {
  271. ["Part"] = {
  272. Create = function(Parent, Material, Reflectance, Transparency, BColor, Name, Size)
  273. local Part = Create("Part"){
  274. Parent = Parent,
  275. Reflectance = Reflectance,
  276. Transparency = Transparency,
  277. CanCollide = false,
  278. Locked = true,
  279. BrickColor = BrickColor.new(tostring(BColor)),
  280. Name = Name,
  281. Size = Size,
  282. Material = Material,
  283. }
  284. RemoveOutlines(Part)
  285. return Part
  286. end;
  287. };
  288.  
  289. ["Mesh"] = {
  290. Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  291. local Msh = Create(Mesh){
  292. Parent = Part,
  293. Offset = OffSet,
  294. Scale = Scale,
  295. }
  296. if Mesh == "SpecialMesh" then
  297. Msh.MeshType = MeshType
  298. Msh.MeshId = MeshId
  299. end
  300. return Msh
  301. end;
  302. };
  303.  
  304. ["Mesh"] = {
  305. Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  306. local Msh = Create(Mesh){
  307. Parent = Part,
  308. Offset = OffSet,
  309. Scale = Scale,
  310. }
  311. if Mesh == "SpecialMesh" then
  312. Msh.MeshType = MeshType
  313. Msh.MeshId = MeshId
  314. end
  315. return Msh
  316. end;
  317. };
  318.  
  319. ["Weld"] = {
  320. Create = function(Parent, Part0, Part1, C0, C1)
  321. local Weld = Create("Weld"){
  322. Parent = Parent,
  323. Part0 = Part0,
  324. Part1 = Part1,
  325. C0 = C0,
  326. C1 = C1,
  327. }
  328. return Weld
  329. end;
  330. };
  331.  
  332. ["Sound"] = {
  333. Create = function(id, par, vol, pit)
  334. coroutine.resume(coroutine.create(function()
  335. local S = Create("Sound"){
  336. Volume = vol,
  337. Pitch = pit or 1,
  338. SoundId = id,
  339. Parent = par or workspace,
  340. }
  341. Instance.new("DistortionSoundEffect", S).Level = 1
  342. wait()
  343. S:play()
  344. game:GetService("Debris"):AddItem(S, 10)
  345. end))
  346. end;
  347. };
  348.  
  349. ["ParticleEmitter"] = {
  350. Create = function(Parent, Color1, Color2, LightEmission, Size, Texture, Transparency, ZOffset, Accel, Drag, LockedToPart, VelocityInheritance, EmissionDirection, Enabled, LifeTime, Rate, Rotation, RotSpeed, Speed, VelocitySpread)
  351. local fp = Create("ParticleEmitter"){
  352. Parent = Parent,
  353. Color = ColorSequence.new(Color1, Color2),
  354. LightEmission = LightEmission,
  355. Size = Size,
  356. Texture = Texture,
  357. Transparency = Transparency,
  358. ZOffset = ZOffset,
  359. Acceleration = Accel,
  360. Drag = Drag,
  361. LockedToPart = LockedToPart,
  362. VelocityInheritance = VelocityInheritance,
  363. EmissionDirection = EmissionDirection,
  364. Enabled = Enabled,
  365. Lifetime = LifeTime,
  366. Rate = Rate,
  367. Rotation = Rotation,
  368. RotSpeed = RotSpeed,
  369. Speed = Speed,
  370. VelocitySpread = VelocitySpread,
  371. }
  372. return fp
  373. end;
  374. };
  375. }
  376.  
  377. function rayCast(Position, Direction, Range, Ignore)
  378. return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore)
  379. end
  380.  
  381. local function GetNearest(obj, distance)
  382. local last, lastx = distance + 1
  383. for i, v in pairs(workspace:GetChildren()) do
  384. if v:IsA'Model' and v ~= Character and v:findFirstChild('Humanoid') and v:findFirstChild('Torso') and v:findFirstChild('Humanoid').Health > 0 then
  385. local t = v.Torso
  386. local dist = (t.Position - obj.Position).magnitude
  387. if dist <= distance then
  388. if dist < last then
  389. last = dist
  390. lastx = v
  391. end
  392. end
  393. end
  394. end
  395. return lastx
  396. end
  397.  
  398. --[[ Credits to Kert109 (Ninja_Deer) for the Damage function. Fenrier for the Magnitude Damage ]]--
  399.  
  400. function Damage(hit, damage, cooldown, Color1, Color2, HSound, HPitch)
  401. for i, v in pairs(hit:GetChildren()) do
  402. if v:IsA("Humanoid") and hit.Name ~= Character.Name then
  403. local find = v:FindFirstChild("DebounceHit")
  404. if not find then
  405. if v.Parent:findFirstChild("Head") then
  406. local BillG = Create("BillboardGui"){
  407. Parent = v.Parent.Head,
  408. Size = UDim2.new(1, 0, 1, 0),
  409. Adornee = v.Parent.Head,
  410. StudsOffset = Vector3.new(math.random(-3, 3), math.random(3, 5), math.random(-3, 3)),
  411. }
  412. local TL = Create("TextLabel"){
  413. Parent = BillG,
  414. Size = UDim2.new(3, 3, 3, 3),
  415. BackgroundTransparency = 1,
  416. Text = tostring(damage).."-",
  417. TextColor3 = Color1.Color,
  418. TextStrokeColor3 = Color2.Color,
  419. TextStrokeTransparency = 0,
  420. TextXAlignment = Enum.TextXAlignment.Center,
  421. TextYAlignment = Enum.TextYAlignment.Center,
  422. FontSize = Enum.FontSize.Size18,
  423. Font = "ArialBold",
  424. }
  425. coroutine.resume(coroutine.create(function()
  426. swait(1)
  427. for i = 0, 1, .1 do
  428. swait(.1)
  429. BillG.StudsOffset = BillG.StudsOffset + Vector3.new(0, .1, 0)
  430. end
  431. BillG:Destroy()
  432. end))
  433. end
  434. v.Health = v.Health - damage
  435. local bool = Create("BoolValue"){
  436. Parent = v,
  437. Name = "DebounceHit",
  438. }
  439. if HSound ~= nil and HPitch ~= nil then
  440. CFuncs["Sound"].Create(HSound, hit, 1, HPitch)
  441. end
  442. game:GetService("Debris"):AddItem(bool, cooldown)
  443. end
  444. end
  445. end
  446. end
  447.  
  448. function MagnitudeDamage(Part, magni, mindam, maxdam, Color1, Color2, HSound, HPitch)
  449. for _, c in pairs(workspace:children()) do
  450. local hum = c:findFirstChild("Humanoid")
  451. if hum ~= nil then
  452. local head = c:findFirstChild("Torso")
  453. if head ~= nil then
  454. local targ = head.Position - Part.Position
  455. local mag = targ.magnitude
  456. if mag <= magni and c.Name ~= Player.Name then
  457. Damage(head.Parent, math.random(mindam, maxdam), 0.5, Color1, Color2, HSound, HPitch)
  458. end
  459. end
  460. end
  461. end
  462. end
  463.  
  464. Handle = CFuncs["Part"].Create(m, Enum.Material.SmoothPlastic, 0, 1, "Medium stone grey", "Handle", Vector3.new(0.399999946, 0.899999976, 0.400000095))
  465. HandleWeld = CFuncs["Weld"].Create(m, Character["Right Arm"], Handle, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(-0.199958801, -0.0500774384, -1.09998882, -1, 0, 0, 0, 0, -1, -0, -1, -0))
  466. FakeHandle = CFuncs["Part"].Create(m, Enum.Material.SmoothPlastic, 0, 1, "Medium stone grey", "FakeHandle", Vector3.new(0.399999946, 0.899999976, 0.400000095))
  467. FakeHandleWeld = CFuncs["Weld"].Create(m, Handle, FakeHandle, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(-0.199996948, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1))
  468. Barrel = CFuncs["Part"].Create(m, Enum.Material.SmoothPlastic, 0, 1, "Medium stone grey", "Barrel", Vector3.new(0.399999946, 0.399999976, 0.400000095))
  469. BarrelWeld = CFuncs["Weld"].Create(m, FakeHandle, Barrel, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(0, -0.749999046, -1.50000024, 1, 0, 0, 0, 1, 0, 0, 0, 1))
  470. Part = CFuncs["Part"].Create(m, Enum.Material.SmoothPlastic, 0, 0, "Medium stone grey", "Part", Vector3.new(0.399999946, 0.299999952, 0.400000095))
  471. PartWeld = CFuncs["Weld"].Create(m, FakeHandle, Part, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(0, -0.300000191, -0.400000095, 1, 0, 0, 0, 1, 0, 0, 0, 1))
  472. CFuncs["Mesh"].Create("SpecialMesh", Part, Enum.MeshType.FileMesh, "rbxassetid://435840330", Vector3.new(0, 0, 0), Vector3.new(0.00200000009, 0.00200000009, 0.00200000009))
  473. Part.Mesh.TextureId = "rbxassetid://435840335"
  474.  
  475. local lightning = Instance.new("ParticleEmitter",Torso)
  476. lightning.Texture = "http://www.roblox.com/asset/?id=281983242"
  477. lightning.LightEmission = 0.55
  478. lightning.Color = ColorSequence.new(Color3.new(255,255,0),Color3.new(255,255,0))
  479. lightning.LockedToPart = true
  480. lightning.Rate = 30
  481. lightning.Lifetime = NumberRange.new(0.03, 0.03)
  482. lightning.Rotation = NumberRange.new(360, 360)
  483. lightning.Size = NumberSequence.new(3,3,3)
  484. lightning.Transparency = NumberSequence.new(0,0)
  485. lightning.Speed = NumberRange.new(0,0)
  486. lightning.VelocitySpread = NumberRange.new(0,0)
  487. lightning.RotSpeed = NumberRange.new(30000.002, 30000.002)
  488. lightning.ZOffset = 3
  489. lightning.Parent = Character.Torso
  490. lightning.Enabled = false
  491.  
  492. local eeeffecto = Instance.new("ParticleEmitter",Torso)
  493. eeeffecto.Texture = "http://www.roblox.com/asset/?id=305943367"
  494. eeeffecto.LightEmission = 0.3
  495. eeeffecto.Color = ColorSequence.new(Color3.new(255,255,0),Color3.new(255,255,0))
  496. eeeffecto.LockedToPart = true
  497. eeeffecto.Rate = 60
  498. eeeffecto.Lifetime = NumberRange.new(0.039, 0.039)
  499. eeeffecto.Rotation = NumberRange.new(0,0)
  500. eeeffecto.Size = NumberSequence.new(9,9,9)
  501. eeeffecto.Transparency = NumberSequence.new(0,0)
  502. eeeffecto.Speed = NumberRange.new(0,0)
  503. eeeffecto.VelocitySpread = NumberRange.new(0,0)
  504. eeeffecto.RotSpeed = NumberRange.new(0,0)
  505. eeeffecto.ZOffset = 2
  506. eeeffecto.Parent = Character.Torso
  507. eeeffecto.Enabled = false
  508. lightning.Enabled = true
  509. eeeffecto.Enabled = true
  510.  
  511. EffectModel = Instance.new("Model", Character)
  512. EffectModel.Name = "Effects"
  513.  
  514. Effects = {
  515. ["Block"] = {
  516. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type)
  517. local prt = CFuncs["Part"].Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  518. prt.Anchored = true
  519. prt.CFrame = cframe
  520. local msh = CFuncs["Mesh"].Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  521. game:GetService("Debris"):AddItem(prt, 10)
  522. if Type == 1 or Type == nil then
  523. table.insert(Effects, {
  524. prt,
  525. "Block1",
  526. delay,
  527. x3,
  528. y3,
  529. z3,
  530. msh
  531. })
  532. elseif Type == 2 then
  533. table.insert(Effects, {
  534. prt,
  535. "Block2",
  536. delay,
  537. x3,
  538. y3,
  539. z3,
  540. msh
  541. })
  542. end
  543. end;
  544. };
  545.  
  546. ["Cylinder"] = {
  547. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  548. local prt = CFuncs["Part"].Create(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.2, 0.2, 0.2))
  549. prt.Anchored = true
  550. prt.CFrame = cframe
  551. local msh = CFuncs["Mesh"].Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  552. game:GetService("Debris"):AddItem(prt, 2)
  553. Effects[#Effects + 1] = {
  554. prt,
  555. "Cylinder",
  556. delay,
  557. x3,
  558. y3,
  559. z3
  560. }
  561. end;
  562. };
  563.  
  564. ["Sphere"] = {
  565. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  566. local prt = CFuncs["Part"].Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  567. prt.Anchored = true
  568. prt.CFrame = cframe
  569. local msh = CFuncs["Mesh"].Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  570. game:GetService("Debris"):AddItem(prt, 10)
  571. table.insert(Effects, {
  572. prt,
  573. "Cylinder",
  574. delay,
  575. x3,
  576. y3,
  577. z3,
  578. msh
  579. })
  580. end;
  581. };
  582.  
  583. ["Elec"] = {
  584. Create = function(cff, x, y, z)
  585. local prt = CFuncs["Part"].Create(workspace, "Neon", 0, 0, BrickColor.new("Lime green"), "Part", Vector3.new(1, 1, 1))
  586. prt.Anchored = true
  587. prt.CFrame = cff * CFrame.new(math.random(-x, x), math.random(-y, y), math.random(-z, z))
  588. prt.CFrame = CFrame.new(prt.Position)
  589. game:GetService("Debris"):AddItem(prt, 2)
  590. local xval = math.random() / 2
  591. local yval = math.random() / 2
  592. local zval = math.random() / 2
  593. local msh = CFuncs["Mesh"].Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(xval, yval, zval))
  594. table.insert(Effects, {
  595. prt,
  596. "Elec",
  597. 0.1,
  598. x,
  599. y,
  600. z,
  601. xval,
  602. yval,
  603. zval
  604. })
  605. end;
  606.  
  607. };
  608.  
  609. ["Ring"] = {
  610. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  611. local prt = CFuncs["Part"].Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  612. prt.Anchored = true
  613. prt.CFrame = cframe
  614. local msh = CFuncs["Mesh"].Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  615. game:GetService("Debris"):AddItem(prt, 10)
  616. table.insert(Effects, {
  617. prt,
  618. "Cylinder",
  619. delay,
  620. x3,
  621. y3,
  622. z3,
  623. msh
  624. })
  625. end;
  626. };
  627.  
  628.  
  629. ["Wave"] = {
  630. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  631. local prt = CFuncs["Part"].Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  632. prt.Anchored = true
  633. prt.CFrame = cframe
  634. local msh = CFuncs["Mesh"].Create("SpecialMesh", prt, "FileMesh", "rbxassetid://20329976", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  635. game:GetService("Debris"):AddItem(prt, 10)
  636. table.insert(Effects, {
  637. prt,
  638. "Cylinder",
  639. delay,
  640. x3,
  641. y3,
  642. z3,
  643. msh
  644. })
  645. end;
  646. };
  647.  
  648. ["Break"] = {
  649. Create = function(brickcolor, cframe, x1, y1, z1)
  650. local prt = CFuncs["Part"].Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
  651. prt.Anchored = true
  652. prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  653. local msh = CFuncs["Mesh"].Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  654. local num = math.random(10, 50) / 1000
  655. game:GetService("Debris"):AddItem(prt, 10)
  656. table.insert(Effects, {
  657. prt,
  658. "Shatter",
  659. num,
  660. prt.CFrame,
  661. math.random() - math.random(),
  662. 0,
  663. math.random(50, 100) / 100
  664. })
  665. end;
  666. };
  667. }
  668.  
  669. Shoot2 = function(orgpos)
  670. local MouseLook = CFrame.new((orgpos + mouse.Hit.p) / 2, mouse.Hit.p)
  671. Effects["Sphere"].Create(BrickColor.new("White"), CFrame.new(orgpos), 5, 5, 5, 3, 3, 3, 0.1)
  672. table.insert(Effects, {
  673. MouseLook.lookVector,
  674. "Shoot2",
  675. 50,
  676. orgpos,
  677. 5,
  678. 7,
  679. 0,
  680. 1,
  681. 2
  682. })
  683. end
  684.  
  685. function bulletstorm()
  686. attack = true
  687. CFuncs["Sound"].Create("rbxassetid://218056315", Torso, 1, 1)
  688. text.Text = "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHHHHHH"
  689. wait(1.5)
  690. for i = 0, 1, 0.025 do
  691. swait()
  692. PlayAnimationFromTable({
  693. CFrame.new(-0, -0, -0, 1, 0, 0, 0, 1, 0, 0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  694. CFrame.new(0, 1.4999907, 3.42726707e-007, 1, 0, 0, 0, 0.996194661, 0.087155968, 0, -0.087155968, 0.996194661) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  695. CFrame.new(0.431798398, 0.400000006, -0.888215482, 0.939692736, 0.342019886, 0, 0, 0, -1, -0.342019916, 0.939692736, 0) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  696. CFrame.new(-0.559965074, 0.300000012, -0.828456283, 0.939692736, -0.342019886, 0, 0, 0, -1, 0.342019916, 0.939692736, 0) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  697. CFrame.new(0.599619746, -1.99127948, 0, 0.996194661, -0.087155968, 0, 0.087155968, 0.996194661, 0, 0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  698. CFrame.new(-0.599619746, -1.99127901, 0, 0.996194661, 0.087155968, 0, -0.087155968, 0.996194661, 0, -0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  699. }, .3, false)
  700. CFuncs["Sound"].Create("rbxassetid://218056315", Torso, 1, 1)
  701. FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-20), math.rad(0)), 0.3)
  702. Shoot2(Barrel.Position)
  703. text.Text = "Golden God"
  704. end
  705.  
  706. attack = false
  707. end
  708.  
  709. function overload()
  710. attack = true
  711. CFuncs["Sound"].Create("rbxassetid://218056315", Torso, 1, 1)
  712. text.Text = "BULLETSTORM!"
  713. Shoot2(LeftArm.Position)
  714. Shoot2(RightArm.Position)
  715. Shoot2(RightLeg.Position)
  716. Shoot2(LeftLeg.Position)
  717. Shoot2(Head.Position)
  718. Shoot2(Torso.Position)
  719. wait(0)
  720. attack = false
  721. text.Text = "Golden God"
  722. end
  723.  
  724. function overcharge()
  725. attack = true
  726. text.Text = "BULLET STORM!"
  727. CFuncs["Sound"].Create("rbxassetid://218056315", Torso, 1, 1)
  728. for i = 0, 1, 0.15 do
  729. swait()
  730. PlayAnimationFromTable({
  731. CFrame.new(-0.0325974114, -4.05311584e-006, 0.110728048, 0.64278698, 0, -0.766044974, 0, 1, 0, 0.766044974, 0, 0.64278698),
  732. CFrame.new(0, 1.50000095, 0, 0.64278698, 0, 0.766044974, 0, 1, 0, -0.766044974, 0, 0.64278698),
  733. CFrame.new(1.10100186, 0.535800219, -0.637803555, 0.658456147, 0.673041463, 0.336824596, 0.280167073, 0.196174845, -0.939692438, -0.698528469, 0.713113427, -0.0593915135),
  734. CFrame.new(-1.62758517, 0.073027119, -0.378663093, 0.90510416, 0.321394593, -0.278374165, -0.392632991, 0.883023262, -0.25711751, 0.163174719, 0.342016995, 0.92541796),
  735. CFrame.new(0.644929826, -1.96549833, 0.164695352, 0.962249994, -0.148305506, 0.228211343, 0.0871559754, 0.962249756, 0.257835865, -0.257834762, -0.22821258, 0.938850582),
  736. CFrame.new(-0.750219464, -1.99537396, -0.240616962, 0.862504363, 0.0818999186, 0.499378443, -0.08583197, 0.99619472, -0.0151344473, -0.498717606, -0.0298091136, 0.866251826),
  737. }, .5, false)
  738. end
  739. wait(3)
  740. Shoot2(Barrel.Position)
  741. Shoot2(Barrel.Position)
  742. Shoot2(Handle.Position)
  743. Shoot2(Handle.Position)
  744. Shoot2(FakeHandle.Position)
  745. Shoot2(FakeHandle.Position)
  746. Shoot2(Barrel.Position)
  747. Shoot2(Barrel.Position)
  748. Shoot2(Handle.Position)
  749. Shoot2(Handle.Position)
  750. Shoot2(FakeHandle.Position)
  751. Shoot2(FakeHandle.Position)
  752. Shoot2(Barrel.Position)
  753. Shoot2(Barrel.Position)
  754. Shoot2(Handle.Position)
  755. Shoot2(Handle.Position)
  756. Shoot2(FakeHandle.Position)
  757. Shoot2(FakeHandle.Position)
  758. Shoot2(Barrel.Position)
  759. Shoot2(Barrel.Position)
  760. Shoot2(Handle.Position)
  761. Shoot2(Handle.Position)
  762. Shoot2(FakeHandle.Position)
  763. Shoot2(FakeHandle.Position)
  764. for i = 0, 1, 0.15 do
  765. swait()
  766. PlayAnimationFromTable({
  767. CFrame.new(2.70828605e-006, -0.256154776, -0.071654655, 0.499999046, -1.78813579e-007, -0.866026044, 0.150384009, 0.984807789, 0.0868238211, 0.852869093, -0.173648283, 0.492402941),
  768. CFrame.new(4.34633694e-006, 1.49999607, 2.42484384e-006, 0.646143615, 0.0549410731, 0.761235893, -0.0851004422, 0.996372402, 0.000322267413, -0.758456767, -0.0649897307, 0.648474991),
  769. CFrame.new(1.86507177, 0.598104239, 0.183552518, -0.114682339, -0.981059372, -0.156110525, 0.981060445, -0.0871559381, -0.172987223, 0.156104773, -0.172992408, 0.9724738),
  770. CFrame.new(-1.52644157, 0.0874626189, -0.302744657, 0.95125103, 0.20658794, -0.229004204, -0.254887104, 0.944645047, -0.2065873, 0.173649222, 0.254886597, 0.951251268),
  771. CFrame.new(0.623469114, -1.90178788, 0.0298061967, 0.992532074, -0.0928985924, 0.079056859, 0.0757590532, 0.97739321, 0.197391063, -0.0956070125, -0.189927697, 0.977131963),
  772. CFrame.new(-0.786503196, -1.67652178, -0.389780819, 0.631277382, 0.179900557, 0.754403591, -0.0723632798, 0.982144117, -0.173656344, -0.772174001, 0.0550341941, 0.6330235),
  773. }, .35, false)
  774. text.Text = "Golden God"
  775. end
  776. attack = false
  777. end
  778.  
  779. function attackone()
  780. attack = true
  781. text.Text = " "
  782.  
  783. howtobasic1 = Instance.new("Sound", game.Players.LocalPlayer.Character.Torso)
  784. howtobasic1.Volume = 45
  785. howtobasic1.SoundId = "rbxassetid://460112630"
  786. howtobasic2 = Instance.new("Sound", game.Players.LocalPlayer.Character.Torso)
  787. howtobasic2.Volume = 45
  788. howtobasic2.SoundId = "rbxassetid://460112630"
  789. howtobasic3 = Instance.new("Sound", game.Players.LocalPlayer.Character.Torso)
  790. howtobasic3.Volume = 45
  791. howtobasic3.SoundId = "rbxassetid://460112630"
  792. howtobasic = Instance.new("Sound", game.Players.LocalPlayer.Character.Torso)
  793. howtobasic.Volume = 45
  794. howtobasic.SoundId = "rbxassetid://460112630"
  795.  
  796. local Math = math.random(1,4)
  797. if Math == 1 then
  798. howtobasic:Play()
  799. end
  800. if Math == 2 then
  801. howtobasic1:Play()
  802. end
  803. if Math == 3 then
  804. howtobasic2:Play()
  805. end
  806. if Math == 4 then
  807. howtobasic3:Play()
  808. end
  809. for i = 0, 1, 0.025 do
  810. swait()
  811. PlayAnimationFromTable({
  812. CFrame.new(-0, -0, -0, 1, 0, 0, 0, 1, 0, 0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  813. CFrame.new(0, 1.4999907, 3.42726707e-007, 1, 0, 0, 0, 0.996194661, 0.087155968, 0, -0.087155968, 0.996194661) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  814. CFrame.new(0.431798398, 0.400000006, -0.888215482, 0.939692736, 0.342019886, 0, 0, 0, -1, -0.342019916, 0.939692736, 0) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  815. CFrame.new(-0.559965074, 0.300000012, -0.828456283, 0.939692736, -0.342019886, 0, 0, 0, -1, 0.342019916, 0.939692736, 0) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  816. CFrame.new(0.599619746, -1.99127948, 0, 0.996194661, -0.087155968, 0, 0.087155968, 0.996194661, 0, 0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  817. CFrame.new(-0.599619746, -1.99127901, 0, 0.996194661, 0.087155968, 0, -0.087155968, 0.996194661, 0, -0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  818. }, .3, false)
  819. FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-20), math.rad(0)), 0.3)
  820. end
  821. CFuncs["Sound"].Create("rbxassetid://244510642", Barrel, 5, 1)
  822. text.Text = "Golden God"
  823. Shoot2(Barrel.Position)
  824. for i = 0, 1, 0.15 do
  825. swait()
  826. RootPart.Velocity = RootPart.CFrame.lookVector * -50
  827. PlayAnimationFromTable({
  828. CFrame.new(-0, -0.281125277, 0.157014638, 1, 0, -0, 0, 0.906307876, -0.422617942, 0, 0.422617942, 0.906307876) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  829. CFrame.new(0, 1.4999938, 1.05202198e-005, 1, 0, -0, 0, 0.965925813, 0.258818924, -0, -0.258818924, 0.965925813) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  830. CFrame.new(0.406597674, 0.817824185, -0.957423151, 0.939692974, 0.280165672, -0.196174338, -5.36441803e-007, -0.573575616, -0.819152534, -0.34201926, 0.769751906, -0.538984895) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  831. CFrame.new(-0.506752789, 0.775180221, -0.974653006, 0.939692974, -0.280165732, 0.196174279, 5.36441803e-007, -0.573575556, -0.819152713, 0.34201926, 0.769752145, -0.538984716) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  832. CFrame.new(0.566868722, -1.61683154, -0.13679418, 0.954536259, -0.174988821, -0.241328761, 0.172366679, 0.984509468, -0.0321052969, 0.243208498, -0.0109513998, 0.969912171) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  833. CFrame.new(-0.545306504, -1.37044179, -0.679420352, 0.996202111, 0.0754783303, 0.0434113704, -0.0434117466, 0.862729907, -0.503797948, -0.0754781216, 0.49999994, 0.862729967) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  834. }, .6, false)
  835. FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(-30), math.rad(-20), math.rad(0)), 0.3)
  836. end
  837. for i = 0, 1, 0.15 do
  838. swait()
  839. RootPart.Velocity = RootPart.CFrame.lookVector * -100
  840. PlayAnimationFromTable({
  841. CFrame.new(-0, -0.795007467, 0.0831707418, 1, 0, -0, 0, 0.76604414, -0.642788053, 0, 0.642788053, 0.76604414) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  842. CFrame.new(0, 1.49999774, 1.20103359e-005, 1, 0, -0, 0, 0.965925634, 0.258819878, -0, -0.258819878, 0.965925634) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  843. CFrame.new(1.70605683, 1.21151328, -0.185158521, 0.893217862, -0.29338178, -0.340718448, -0.340719074, -0.936116338, -0.0871595442, -0.293381065, 0.193941653, -0.936116695) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  844. CFrame.new(-1.69524968, 1.05172348, -0.252849877, 0.812758088, 0.493294626, 0.309975445, 0.582562625, -0.694268882, -0.422624737, 0.00672781467, 0.524071693, -0.851647615) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  845. CFrame.new(0.689150453, -1.88461804, -0.0157705098, 0.954536736, -0.174989104, -0.241326213, 0.172367141, 0.984509468, -0.0321044922, 0.243205875, -0.0109517872, 0.969912887) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  846. CFrame.new(-0.536899447, -1.34506011, -0.583059072, 0.99620223, 0.0226762109, 0.0840658173, -0.043412663, 0.966281295, 0.253803402, -0.0754759163, -0.256489068, 0.963595748) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  847. }, .2, false)
  848. FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-50), math.rad(0)), 0.3)
  849. end
  850. for i = 0, 1, 0.05 do
  851. swait()
  852. RootPart.Velocity = RootPart.CFrame.lookVector * -50
  853. PlayAnimationFromTable({
  854. CFrame.new(-0, -2.09708667, 0.108620644, 1, 0, -0, 0, 0.573575675, -0.819152594, 0, 0.819152594, 0.573575675) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  855. CFrame.new(0, 1.53697455, -0.422635257, 1, 0, -0, 0, 0.766043842, 0.64278841, -0, -0.64278841, 0.766043842) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  856. CFrame.new(1.57810855, 0.650130272, 0.33058399, 0.930655897, -0.284022599, -0.230674848, 0.352510452, 0.527023435, 0.773293555, -0.0980618149, -0.800985396, 0.590598404) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  857. CFrame.new(-1.38994181, 0.87733829, 0.667137444, 0.963715255, 0.08906921, 0.251633942, -0.25866431, 0.0788001418, 0.962747812, 0.0659223944, -0.992903471, 0.0989798903) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  858. CFrame.new(0.774198592, -1.52057803, -0.607582211, 0.954536974, -0.272207022, -0.121501081, 0.172365844, 0.83655864, -0.520057499, 0.243206039, 0.475471497, 0.845445395) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  859. CFrame.new(-0.530096769, -1.05517173, -0.660005629, 0.99620223, 0.0226761587, 0.0840661526, -0.0434127897, 0.966280818, 0.253804684, -0.0754762068, -0.256490231, 0.96359539) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  860. }, .3, false)
  861. FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-60), math.rad(0)), 0.3)
  862. end
  863. for i = 0, 1, 0.13 do
  864. swait()
  865. PlayAnimationFromTable({
  866. CFrame.new(-0, -1.01349139, -0.251608461, 1, 0, 0, 0, 0.707105339, 0.707108378, 0, -0.707108378, 0.707105339) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  867. CFrame.new(0.0127754211, 1.44207788, 0.0749337673, 1, 0, 0, 0, 0.939691544, -0.342023343, 0, 0.342023343, 0.939691544) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  868. CFrame.new(1.62296665, 0.191783041, -0.192457974, 0.930656254, -0.329096794, 0.159920022, 0.352511466, 0.923570275, -0.150843769, -0.098055169, 0.196757287, 0.975536823) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  869. CFrame.new(-0.870643735, 0.71258086, -0.942903101, 0.18127799, -0.372358024, -0.910213113, -0.781424284, 0.507405519, -0.363202393, 0.597088516, 0.777103186, -0.19898814) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  870. CFrame.new(0.214147568, -1.73508716, -0.0895051956, 0.924306214, 0.282332808, -0.256800473, -0.113861978, 0.846218646, 0.520528436, 0.364271581, -0.451887846, 0.814311981) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  871. CFrame.new(-0.535767198, -0.599929333, -0.996632636, 0.996202111, 0.0754788443, 0.0434101112, -0.0434126705, 0.862728953, -0.503799856, -0.0754773915, 0.500001788, 0.862729192) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  872. }, .3, false)
  873. end
  874. attack = false
  875. end
  876.  
  877. --[[Attacks]]--
  878.  
  879. mouse.Button1Down:connect(function()
  880. if attack == false and attacktype == 1 then
  881. attackone()
  882. end
  883. end)
  884.  
  885.  
  886. mouse.KeyDown:connect(function(k)
  887. k = k:lower()
  888. if attack == false and k == 'q' then
  889. bulletstorm()
  890. elseif attack == false and k == 'e' then
  891. overload()
  892. elseif attack == false and k == 'r' then
  893. overcharge()
  894. end
  895. end)
  896.  
  897. while true do
  898. swait()
  899. for i, v in pairs(Character:GetChildren()) do
  900. if v:IsA("Part") then
  901. v.Material = "SmoothPlastic"
  902. elseif v:IsA("Accessory") then
  903. v:WaitForChild("Handle").Material = "SmoothPlastic"
  904. end
  905. end
  906. Torsovelocity = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude
  907. velocity = RootPart.Velocity.y
  908. sine = sine + change
  909. local hit, pos = rayCast(RootPart.Position, (CFrame.new(RootPart.Position, RootPart.Position - Vector3.new(0, 1, 0))).lookVector, 4, Character)
  910. if equipped == true or equipped == false then
  911. if RootPart.Velocity.y > 1 and hit == nil then
  912. Anim = "Jump"
  913. if attack == false then
  914. PlayAnimationFromTable({
  915. CFrame.new(-0, -0, -0, 1, 0, 0, 0, 1, 0, 0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  916. CFrame.new(0, 1.49221826, -0.044082582, 1, 0, 0, 0, 0.984807849, 0.173647985, 0, -0.173647985, 0.984807849) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  917. CFrame.new(1.66304386, 0.182627335, 0.00782334805, 0.883022726, -0.392632574, 0.257119894, 0.321392894, 0.905103981, 0.2783764, -0.342019886, -0.163176134, 0.925416708) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  918. CFrame.new(-1.66570556, 0.224230319, 0.110721856, 0.903736115, 0.408218145, -0.128915116, -0.34750703, 0.875426054, 0.33595863, 0.25000003, -0.258819014, 0.933012724) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  919. CFrame.new(0.499999166, -1.99999452, 4.76837158e-007, 0.984807849, -5.94328526e-007, -0.173648044, 0.0449439958, 0.965925872, 0.254886925, 0.167730987, -0.258819073, 0.951251388) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  920. CFrame.new(-0.499999404, -1.51703107, -0.129407585, 0.965925753, 6.6929374e-007, 0.258819193, -0.0669879839, 0.965925813, 0.24999994, -0.24999994, -0.258819163, 0.933012724) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  921. }, .3, false)
  922. end
  923. elseif RootPart.Velocity.y < -60 and hit == nil then
  924. Anim = "Fall"
  925. if attack == false then
  926. PlayAnimationFromTable({
  927. CFrame.new(-0, -0, -0, 1, 0, 0, 0, 1, 0, 0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  928. CFrame.new(0, 1.49221873, -0.0440826714, 1, 0, 0, 0, 0.984807849, 0.173647985, 0, -0.173647985, 0.984807849) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  929. CFrame.new(1.76076102, 0.406842887, 0.0212866664, 0.695482016, -0.670965135, 0.257119834, 0.611573994, 0.74059701, 0.278376371, -0.377202988, -0.0363579579, 0.925416648) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  930. CFrame.new(-1.68029141, 0.390803367, 0.155905366, 0.70961535, 0.692695498, -0.128914997, -0.625963271, 0.703777075, 0.335958213, 0.323444158, -0.157705069, 0.933012843) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  931. CFrame.new(0.693307817, -1.96826017, -0.0605875254, 0.986561239, -0.127662987, -0.101976946, 0.137943029, 0.985269904, 0.101069227, 0.0875720233, -0.113777988, 0.989639223) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  932. CFrame.new(-0.526552737, -1.81498528, -0.152177691, 0.965925574, 0.0449441113, 0.254888207, -0.066988036, 0.994663239, 0.0784704387, -0.250001162, -0.0928710476, 0.963781357) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  933. }, .3, false)
  934. end
  935. elseif Torsovelocity < 1 and hit ~= nil then
  936. Anim = "Idle"
  937. if attack == false then
  938. change = 1
  939. PlayAnimationFromTable({
  940. CFrame.new(1.22602091e-006, -0.219458103, 1.46111324e-006, 0.76604414, 0, 0.642788053, 0, 1, 0, -0.642788053, 0, 0.76604414) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  941. CFrame.new(0, 1.49999201, 0, 0.707106233, 0, -0.707107306, 0, 1, 0, 0.707107306, 0, 0.707106233) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  942. CFrame.new(0.571566343, -0.0739164352, -0.639066696, 0.939692855, 0.340718329, -0.0298085809, -0.241844058, 0.600305915, -0.762328327, -0.241844922, 0.723563433, 0.646503866) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  943. CFrame.new(-0.628383756, -0.12163578, -0.696761668, 0.939692736, -0.342020065, -5.06639481e-007, 0.196173996, 0.538984895, -0.819152653, 0.280166954, 0.769751549, 0.573575616) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  944. CFrame.new(0.624118924, -1.79798961, 0.0678238794, 0.995454907, -0.0383867361, -0.0871553123, 0.0385330059, 0.999257326, -4.09960694e-006, 0.0870907605, -0.00335427374, 0.996194839) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  945. CFrame.new(-0.53866595, -1.82180798, 0.00821807235, 0.977763176, 0.0281341001, 0.207816422, -0.0287620034, 0.999586344, -1.4934686e-007, -0.207730502, -0.00597707182, 0.978167892) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  946. }, .3, false)
  947. FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-20), math.rad(0)), 0.3)
  948. end
  949. elseif Torsovelocity > 2 and hit ~= nil then
  950. Anim = "Walk"
  951. if attack == false then
  952. change = 3
  953. PlayAnimationFromTable({
  954. CFrame.new(0, -0.0240751095, -0.146390602, 1, 0, 0, 0, 0.965925872, 0.258818984, 0, -0.258818984, 0.965925872) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  955. CFrame.new(0, 1.49999237, -1.81794167e-006, 1, 0, 0, 0, 0.984807789, -0.173647881, 0, 0.173647881, 0.984807789) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  956. CFrame.new(0.172261134, 0.427689523, -1.09730911, 0.644483984, 0.748984814, -0.153825179, 0.413525045, -0.510645986, -0.753815472, -0.643146515, 0.422211438, -0.638827145) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  957. CFrame.new(-1.1922102, 0.363029838, -0.448653877, 0.935289383, -0.110854559, -0.33607316, -0.341521561, -0.531564534, -0.775114357, -0.0927196145, 0.839732468, -0.535025835) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0),
  958. CFrame.new(.5, -1.85 - 0.5 * math.cos(sine / 8) / 2, 0 + 1.8 * math.sin(sine / 8) / 2) * angles(math.rad(-50 * math.sin(sine / 8)), math.rad(0), math.rad(0)),
  959. CFrame.new(-.5, -1.85 + 0.5 * math.cos(sine / 8) / 2, 0 - 1.8 * math.sin(sine / 8) / 2) * angles(math.rad(50 * math.sin(sine / 8)), math.rad(0), math.rad(0)),
  960. }, .3, false)
  961. FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-30), math.rad(0)), 0.3)
  962. end
  963. end
  964. end
  965. if 0 < #Effects then
  966. for e = 1, #Effects do
  967. if Effects[e] ~= nil then
  968. local Thing = Effects[e]
  969. if Thing ~= nil then
  970. local Part = Thing[1]
  971. local Mode = Thing[2]
  972. local Delay = Thing[3]
  973. local IncX = Thing[4]
  974. local IncY = Thing[5]
  975. local IncZ = Thing[6]
  976. if Thing[2] == "Shoot" then
  977. local Look = Thing[1]
  978. local hit, pos = rayCast(Thing[4], Look, 15, Character)
  979. local mag = (Thing[4] - pos).magnitude
  980. Thing[9] = Thing[9] + 0.5
  981. Thing[5] = Thing[5] + 0.2
  982. Thing[6] = Thing[6] + 0.2
  983. Effects["Cylinder"].Create(BrickColor.new("White"), CFrame.new((Thing[4] + pos) / 2, pos) * angles(1.57, 0, 0), Thing[9], mag * 5, Thing[9], -0.2, 0, -0.2, 0.1)
  984. Thing[4] = Thing[4] + Look * 15
  985. Thing[3] = Thing[3] - 1
  986. if hit ~= nil then
  987. Thing[3] = 0
  988. ref = CFuncs["Part"].Create(workspace, "Neon", 0, 1, BrickColor.new("White"), "Reference", Vector3.new())
  989. ref.Anchored = true
  990. ref.CFrame = CFrame.new(pos)
  991. Effects["Sphere"].Create(BrickColor.new("Bright yellow"), CFrame.new(pos), 5, 5, 5, 1, 1, 1, 0.07)
  992. CFuncs["Sound"].Create("rbxassetid://539881968", ref, 0.1, 1)
  993. game:GetService("Debris"):AddItem(ref, 10)
  994. end
  995. if Thing[3] <= 0 then
  996. table.remove(Effects, e)
  997. end
  998. end
  999. do
  1000. if Thing[2] == "Shoot2" then
  1001. local Look = Thing[1]
  1002. local hit, pos = rayCast(Thing[4], Look, 3, Character)
  1003. local mag = (Thing[4] - pos).magnitude
  1004. Thing[9] = Thing[9] + 0.5
  1005. Thing[5] = Thing[5] + 0.2
  1006. Thing[6] = Thing[6] + 0.2
  1007. Effects["Sphere"].Create(BrickColor.new("Bright yellow"), CFrame.new((Thing[4] + pos) / 2, pos), 25, 25, 25, -5, -5, -5, 0.2)
  1008. Thing[4] = Thing[4] + Look * 3
  1009. Thing[3] = Thing[3] + 5
  1010. if hit ~= nil then
  1011. Thing[3] = 0
  1012. ref = CFuncs["Part"].Create(workspace, "Neon", 0, 1, BrickColor.new("White"), "Reference", Vector3.new())
  1013. ref.Anchored = true
  1014. ref.CFrame = CFrame.new(pos)
  1015. Effects["Sphere"].Create(BrickColor.new("Really yellow"), CFrame.new(pos), 25, 25, 25, 5, 5, 5, 0.01)
  1016. Effects["Sphere"].Create(BrickColor.new("Bright yellow"), CFrame.new(pos), 10, 10, 10, 15, 15, 15, 0.01)
  1017. Effects["Block"].Create(BrickColor.new("Gold"), CFrame.new(pos), 10, 10, 10, 15, 15, 15, 0.01, 1)
  1018. Effects["Wave"].Create(BrickColor.new("Gold"), CFrame.new(pos), 2, 2, 2, 3, 3, 3, 0.01)
  1019. CFuncs["Sound"].Create("rbxassetid://10209236", ref, 1, 1)
  1020. CFuncs["Sound"].Create("rbxassetid://10209236", Sphere, 0.5, 1)
  1021. CFuncs["Sound"].Create("rbxassetid://10209236", Sphere, 0.1, 1)
  1022. local e = Instance.new("Explosion", ref)
  1023. e.Position = ref.Position
  1024. e.BlastRadius = 400
  1025. e.DestroyJointRadiusPercent = 400
  1026. e.Visible = false
  1027. e.ExplosionType = "CratersAndDebris"
  1028. game:GetService("Debris"):AddItem(ref, 2)
  1029. end
  1030. if Thing[3] <= 0 then
  1031. table.remove(Effects, e)
  1032. end
  1033. end
  1034. do
  1035. do
  1036. if Thing[2] ~= "Shoot" and Thing[2] ~= "DecreaseStat" and Thing[2] ~= "showDamage" and Thing[2] ~= "Shoot2" then
  1037. if Thing[1].Transparency <= 1 then
  1038. if Thing[2] == "Block1" then
  1039. Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  1040. Mesh = Thing[7]
  1041. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1042. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1043. else
  1044. if Thing[2] == "Block2" then
  1045. Thing[1].CFrame = Thing[1].CFrame
  1046. Mesh = Thing[7]
  1047. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1048. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1049. else
  1050. if Thing[2] == "Block3" then
  1051. Thing[8].C0 = CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) * Thing[9]
  1052. Mesh = Thing[7]
  1053. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1054. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1055. else
  1056. if Thing[2] == "Cylinder" then
  1057. Mesh = Thing[7]
  1058. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1059. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1060. else
  1061. if Thing[2] == "Cylinder2" then
  1062. Thing[1].CFrame = Thing[1].CFrame * CFrame.new(0, Thing[8], 0)
  1063. Mesh = Thing[7]
  1064. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1065. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1066. else
  1067. if Thing[2] == "Blood" then
  1068. Mesh = Thing[7]
  1069. Thing[1].CFrame = Thing[1].CFrame * CFrame.new(0, 0.5, 0)
  1070. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1071. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1072. else
  1073. if Thing[2] == "Elec" then
  1074. Mesh = Thing[10]
  1075. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[7], Thing[8], Thing[9])
  1076. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1077. else
  1078. if Thing[2] == "Disappear" then
  1079. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1080. end
  1081. end
  1082. end
  1083. end
  1084. end
  1085. end
  1086. end
  1087. end
  1088. else
  1089. Part.Parent = nil
  1090. table.remove(Effects, e)
  1091. end
  1092. end
  1093. end
  1094. end
  1095. end
  1096. end
  1097. end
  1098. end
  1099. end
  1100. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement