Advertisement
SCR1PT_ED1T0R

FE Codex Sonic

Sep 25th, 2018
1,184
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. if game:GetService("RunService"):IsClient()then error("Please run as a server script. Use h/ instead of hl/.")end;print("FE Compatibility: by WaverlyCole");InternalData = {}
  2. do
  3. script.Parent = owner.Character
  4. local Event = Instance.new("RemoteEvent");Event.Name = "UserInput"
  5. local function NewFakeEvent()
  6. local Bind = Instance.new("BindableEvent")
  7. local Fake;Fake = {Connections = {},
  8. fakeEvent=true;
  9. Connect=function(self,Func)
  10. Bind.Event:connect(Func)
  11. self.Connections[Bind] = true
  12. return setmetatable({Connected = true},{
  13. __index = function (self,Index)
  14. if Index:lower() == "disconnect" then
  15. return function() Fake.Connections[Bind] = false;self.Connected = false end
  16. end
  17. return Fake[Index]
  18. end;
  19. __tostring = function() return "Connection" end;
  20. })
  21. end}
  22. Fake.connect = Fake.Connect;return Fake;
  23. end
  24. local Mouse = {Target=nil,Hit=CFrame.new(),KeyUp=NewFakeEvent(),KeyDown=NewFakeEvent(),Button1Up=NewFakeEvent(),Button1Down=NewFakeEvent()}
  25. local UserInputService = {InputBegan=NewFakeEvent(),InputEnded=NewFakeEvent()}
  26. local ContextActionService = {Actions={},BindAction = function(self,actionName,Func,touch,...)
  27. self.Actions[actionName] = Func and {Name=actionName,Function=Func,Keys={...}} or nil
  28. end};ContextActionService.UnBindAction = ContextActionService.BindAction
  29. local function TriggerEvent(self,Event,...)
  30. local Trigger = Mouse[Event]
  31. if Trigger and Trigger.fakeEvent and Trigger.Connections then
  32. for Connection,Active in pairs(Trigger.Connections) do if Active then Connection:Fire(...) end end
  33. end
  34. end
  35. Mouse.TrigEvent = TriggerEvent;UserInputService.TrigEvent = TriggerEvent
  36. Event.OnServerEvent:Connect(function(FiredBy,Input)
  37. if FiredBy.Name ~= owner.Name then return end
  38. if Input.MouseEvent then
  39. Mouse.Target = Input.Target;Mouse.Hit = Input.Hit
  40. else
  41. local Begin = Input.UserInputState == Enum.UserInputState.Begin
  42. if Input.UserInputType == Enum.UserInputType.MouseButton1 then return Mouse:TrigEvent(Begin and "Button1Down" or "Button1Up") end
  43. for _,Action in pairs(ContextActionService.Actions) do
  44. for _,Key in pairs(Action.Keys) do if Key==Input.KeyCode then Action.Function(Action.Name,Input.UserInputState,Input) end end
  45. end
  46. Mouse:TrigEvent(Begin and "KeyDown" or "KeyUp",Input.KeyCode.Name:lower())
  47. UserInputService:TrigEvent(Begin and "InputBegan" or "InputEnded",Input,false)
  48. end
  49. end)
  50. InternalData["Mouse"] = Mouse;InternalData["ContextActionService"] = ContextActionService;InternalData["UserInputService"] = UserInputService
  51. Event.Parent = NLS([[
  52. local Player = owner;local Event = script:WaitForChild("UserInput");local UserInputService = game:GetService("UserInputService");local Mouse = Player:GetMouse()
  53. local Input = function(Input,gameProcessedEvent)
  54. if gameProcessedEvent then return end
  55. Event:FireServer({KeyCode=Input.KeyCode,UserInputType=Input.UserInputType,UserInputState=Input.UserInputState})
  56. end
  57. UserInputService.InputBegan:Connect(Input);UserInputService.InputEnded:Connect(Input)
  58. local Hit,Target
  59. while wait(1/30) do
  60. if Hit ~= Mouse.Hit or Target ~= Mouse.Target then
  61. Hit,Target = Mouse.Hit,Mouse.Target;Event:FireServer({["MouseEvent"]=true,["Target"]=Target,["Hit"]=Hit})
  62. end
  63. end
  64. ]],owner.Character)
  65. end
  66. RealGame = game;game = setmetatable({},{
  67. __index = function (self,Index)
  68. local Sandbox = function (Thing)
  69. if Thing:IsA("Player") then
  70. local RealPlayer = Thing
  71. return setmetatable({},{
  72. __index = function (self,Index)
  73. local Type = type(RealPlayer[Index])
  74. if Type == "function" then
  75. if Index:lower() == "getmouse" or Index:lower() == "mouse" then
  76. return function (self)return InternalData["Mouse"] end
  77. end
  78. return function (self,...)return RealPlayer[Index](RealPlayer,...) end
  79. end
  80. return RealPlayer[Index]
  81. end;
  82. __tostring = function(self) return RealPlayer.Name end
  83. })
  84. end
  85. end
  86. if RealGame[Index] then
  87. local Type = type(RealGame[Index])
  88. if Type == "function" then
  89. if Index:lower() == "getservice" or Index:lower() == "service" then
  90. return function (self,Service)
  91. local FakeServices = {
  92. ["players"] = function()
  93. return setmetatable({},{
  94. __index = function (self2,Index2)
  95. local RealService = RealGame:GetService(Service)
  96. local Type2 = type(Index2)
  97. if Type2 == "function" then
  98. return function (self,...) return RealService[Index2](RealService,...)end
  99. else
  100. if Index2:lower() == "localplayer" then return Sandbox(owner) end
  101. return RealService[Index2]
  102. end
  103. end;
  104. __tostring = function(self) return RealGame:GetService(Service).Name end
  105. })
  106. end;
  107. ["contextactionservice"] = function() return InternalData["ContextActionService"] end;
  108. ["userinputservice"] = function() return InternalData["UserInputService"] end;
  109. ["runservice"] = function()
  110. return setmetatable({},{
  111. __index = function(self2,Index2)
  112. local RealService = RealGame:GetService(Service)
  113. local Type2 = type(Index2)
  114. if Type2 == "function" then
  115. return function (self,...) return RealService[Index2](RealService,...) end
  116. else
  117. local RunServices = {
  118. ["bindtorenderstep"] = function() return function (self,Name,Priority,Function) return RealGame:GetService("RunService").Stepped:Connect(Function) end end;
  119. ["renderstepped"] = function() return RealService["Stepped"] end
  120. }
  121. if RunServices[Index2:lower()] then return RunServices[Index2:lower()]() end
  122. return RealService[Index2]
  123. end
  124. end
  125. })
  126. end
  127. }
  128. if FakeServices[Service:lower()] then return FakeServices[Service:lower()]() end
  129. return RealGame:GetService(Service)
  130. end
  131. end
  132. return function (self,...) return RealGame[Index](RealGame,...) end
  133. else
  134. if game:GetService(Index) then return game:GetService(Index) end
  135. return RealGame[Index]
  136. end
  137. end
  138. return nil
  139. end
  140. });Game = game;owner = game:GetService("Players").LocalPlayer;script = Instance.new("Script");print("Complete! Running...")
  141.  
  142. --[[KillerDarkness0105's/Codex's Sonic script]]--
  143.  
  144.  
  145.  
  146. wait(0.07)
  147. Player=game:GetService("Players").LocalPlayer
  148. Character=Player.Character
  149. PlayerGui=Player.PlayerGui
  150. Backpack=Player.Backpack
  151. Torso=Character.Torso
  152. Head=Character.Head
  153. Humanoid=Character.Humanoid
  154. LeftArm=Character["Left Arm"]
  155. LeftLeg=Character["Left Leg"]
  156. RightArm=Character["Right Arm"]
  157. RightLeg=Character["Right Leg"]
  158. LS=Torso["Left Shoulder"]
  159. LH=Torso["Left Hip"]
  160. RS=Torso["Right Shoulder"]
  161. RH=Torso["Right Hip"]
  162. Face = Head.face
  163. Neck=Torso.Neck
  164. it=Instance.new
  165. attacktype=1
  166. attacktype2=1
  167. vt=Vector3.new
  168. cf=CFrame.new
  169. cn=CFrame.new
  170. euler=CFrame.fromEulerAnglesXYZ
  171. angles=CFrame.Angles
  172. combo = 0
  173. necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  174. necko2=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  175. LHC0=cf(-1,-1,0,-0,-0,-1,0,1,0,1,0,0)
  176. LHC1=cf(-0.5,1,0,-0,-0,-1,0,1,0,1,0,0)
  177. RHC0=cf(1,-1,0,0,0,1,0,1,0,-1,-0,-0)
  178. RHC1=cf(0.5,1,0,0,0,1,0,1,0,-1,-0,-0)
  179. RootPart=Character.HumanoidRootPart
  180. RootJoint=RootPart.RootJoint
  181. RootCF=euler(-1.57,0,3.14)
  182. attack = false
  183. attackdebounce = false
  184. trispeed=.2
  185. attackmode='none'
  186. local idle=0
  187. local Anim="Idle"
  188. stance = false
  189. local ff = 2
  190. noleg = false
  191. evadecooldown = false
  192. Humanoid.Animator.Parent = nil
  193. equip = false
  194. local Effects = {}
  195. attackspeed = 0.14
  196. df = false
  197. Swing = 1
  198. local sine = 0
  199. local change = 1
  200. local val = 0
  201. local speed = 0
  202. local rs = game:GetService("RunService").RenderStepped
  203. cam = workspace.CurrentCamera
  204. local RbxUtility = LoadLibrary("RbxUtility")
  205. local Create = RbxUtility.Create
  206. deb = game:GetService("Debris")
  207. Face.Transparency = 0
  208. --Face.Texture = "rbxassetid://176217905" --176217905
  209. Humanoid.WalkSpeed = 64
  210. local freefall = 0
  211. Head.Running.SoundId = "rbxassetid://758199523"
  212. Head.Running.Volume = 2
  213. local boost = false
  214. Humanoid.JumpPower = 88
  215. local musicnum = 1
  216.  
  217. local spd = Vector3.new(RootPart.Velocity.x,0,RootPart.Velocity.z).magnitude + 10
  218. local dir = Vector3.new(RootPart.Velocity.x,0,RootPart.Velocity.z).unit
  219. local GravPoint = RootPart.Velocity.y
  220. local NV = Vector3.new(0,0,0)
  221. print("Move list")
  222. print("---------")
  223. print("Shift = Boost")
  224. print("Ctrl = Mach Speed Boost")
  225. print("Q = Left QuickStep, E = Right QuickStep")
  226. print("C = Slide, in air to stomp")
  227. print("Jump Then Hold B near a wall to wallrun")
  228. print("M to change music, if you're standing still you'll do a special animation!")
  229. print("Space near a wall to walljump, away from a wall homing attack")
  230. music = Instance.new("Sound",PlayerGui)
  231. music.Volume = 1
  232. music.TimePosition = 0
  233. music.Pitch = 1
  234. music.SoundId = "rbxassetid://1251555494"
  235. music.Looped = true
  236. music:Play()
  237.  
  238.  
  239. boostsound = Instance.new("Sound",PlayerGui)
  240. boostsound.Volume = .6
  241. boostsound.TimePosition = 0
  242. boostsound.Pitch = 1
  243. boostsound.SoundId = "rbxassetid://924922553"
  244. boostsound.Looped = false
  245.  
  246.  
  247.  
  248. stompsound = Instance.new("Sound",PlayerGui)
  249. stompsound.Volume = 2
  250. stompsound.TimePosition = 0
  251. stompsound.Pitch = 1
  252. stompsound.SoundId = "rbxassetid://1295424184"
  253. stompsound.Looped = false
  254.  
  255.  
  256.  
  257. so = function(id,par,vol,pit)
  258. coroutine.resume(coroutine.create(function()
  259. local sou = Instance.new("Sound",par or workspace)
  260. sou.Volume=vol
  261. sou.Pitch=pit or 1
  262. sou.SoundId=id
  263. sou:play()
  264. game:GetService("Debris"):AddItem(sou,8)
  265. end))
  266. end
  267.  
  268. --save shoulders
  269. RSH, LSH=nil, nil
  270. --welds
  271. RW, LW=Instance.new("Weld"), Instance.new("Weld")
  272. RW.Name="Right Shoulder" LW.Name="Left Shoulder"
  273. LH=Torso["Left Hip"]
  274. RH=Torso["Right Hip"]
  275. TorsoColor=Torso.BrickColor
  276. function NoOutline(Part)
  277. Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
  278. end
  279. player=Player
  280. ch=Character
  281. RSH=ch.Torso["Right Shoulder"]
  282. LSH=ch.Torso["Left Shoulder"]
  283. --
  284. RSH.Parent=nil
  285. LSH.Parent=nil
  286. --
  287. RW.Name="Right Shoulder"
  288. RW.Part0=ch.Torso
  289. RW.C0=cf(1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.3, 0, -0.5)
  290. RW.C1=cf(0, 0.5, 0)
  291. RW.Part1=ch["Right Arm"]
  292. RW.Parent=ch.Torso
  293. --
  294. LW.Name="Left Shoulder"
  295. LW.Part0=ch.Torso
  296. LW.C0=cf(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8)
  297. LW.C1=cf(0, 0.5, 0)
  298. LW.Part1=ch["Left Arm"]
  299. LW.Parent=ch.Torso
  300.  
  301.  
  302. newWeld = function(wp0, wp1, wc0x, wc0y, wc0z)
  303. local wld = Instance.new("Weld", wp1)
  304. wld.Part0 = wp0
  305. wld.Part1 = wp1
  306. wld.C0 = CFrame.new(wc0x, wc0y, wc0z)
  307. end
  308. local rs = game:GetService("RunService").RenderStepped
  309.  
  310. newWeld(RootPart, Torso, 0, -1, 0)
  311. Torso.Weld.C1 = CFrame.new(0, -1, 0)
  312. newWeld(Torso, LeftLeg, -0.5, -1, 0)
  313. LeftLeg.Weld.C1 = CFrame.new(0, 1, 0)
  314. newWeld(Torso, RightLeg, 0.5, -1, 0)
  315. RightLeg.Weld.C1 = CFrame.new(0, 1, 0)
  316.  
  317. Player=game:GetService('Players').LocalPlayer
  318. Character=Player.Character
  319. mouse=Player:GetMouse()
  320. m=Instance.new('Model',Character)
  321.  
  322.  
  323. local function weldBetween(a, b)
  324. local weldd = Instance.new("ManualWeld")
  325. weldd.Part0 = a
  326. weldd.Part1 = b
  327. weldd.C0 = CFrame.new()
  328. weldd.C1 = b.CFrame:inverse() * a.CFrame
  329. weldd.Parent = a
  330. return weldd
  331. end
  332.  
  333. ArtificialHB = Instance.new("BindableEvent", script)
  334. ArtificialHB.Name = "Heartbeat"
  335.  
  336. script:WaitForChild("Heartbeat")
  337.  
  338. frame = 1 / 80
  339. tf = 0
  340. allowframeloss = false
  341. tossremainder = false
  342. lastframe = tick()
  343. script.Heartbeat:Fire()
  344. game:GetService("RunService").Heartbeat:connect(function(s, p)
  345. tf = tf + s
  346. if tf >= frame then
  347. if allowframeloss then
  348. script.Heartbeat:Fire()
  349. lastframe = tick()
  350. else
  351. for i = 1, math.floor(tf / frame) do
  352. script.Heartbeat:Fire()
  353. end
  354. lastframe = tick()
  355. end
  356. if tossremainder then
  357. tf = 0
  358. else
  359. tf = tf - frame * math.floor(tf / frame)
  360. end
  361. end
  362. end)
  363.  
  364. --[[]
  365. function swait(num)
  366. if num == 0 or num == nil then
  367. ArtificialHB.Event:wait()
  368. else
  369. for i = 0, num do
  370. ArtificialHB.Event:wait()
  371. end
  372. end
  373. end
  374.  
  375. ]]
  376.  
  377.  
  378.  
  379.  
  380. function swait(num)
  381. if num == 0 or num == nil then
  382. game:service("RunService").Stepped:wait()
  383. else
  384. for i = 0, num do
  385. game:service("RunService").Stepped:wait()
  386. end
  387. end
  388. end
  389.  
  390. function RemoveOutlines(part)
  391. part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10
  392. end
  393.  
  394.  
  395. part = function(formfactor, parent, reflectance, transparency, brickcolor, name, size)
  396. local fp = it("Part")
  397. fp.formFactor = formfactor
  398. fp.Parent = parent
  399. fp.Reflectance = reflectance
  400. fp.Transparency = transparency
  401. fp.CanCollide = false
  402. fp.Locked = true
  403. fp.BrickColor = brickcolor
  404. fp.Name = name
  405. fp.Size = size
  406. fp.Position = Torso.Position
  407. NoOutline(fp)
  408. if fp.BrickColor == BrickColor.new("Dark indigo") then
  409. fp.Material = "Neon"
  410. else
  411. if fp.BrickColor == BrickColor.new("Really black") then
  412. fp.BrickColor = BrickColor.new("Really black")
  413. fp.Material = "Metal"
  414. else
  415. fp.Material = "Neon"
  416. end
  417. end
  418. fp:BreakJoints()
  419. return fp
  420. end
  421.  
  422. mesh = function(Mesh, part, meshtype, meshid, offset, scale)
  423. local mesh = it(Mesh)
  424. mesh.Parent = part
  425. if Mesh == "SpecialMesh" then
  426. mesh.MeshType = meshtype
  427. mesh.MeshId = meshid
  428. end
  429. mesh.Offset = offset
  430. mesh.Scale = scale
  431. return mesh
  432. end
  433.  
  434. weld = function(parent, part0, part1, c0)
  435. local weld = it("Weld")
  436. weld.Parent = parent
  437. weld.Part0 = part0
  438. weld.Part1 = part1
  439. weld.C0 = c0
  440. return weld
  441. end
  442.  
  443. F1 = Instance.new("Folder", Character)
  444. F1.Name = "Effects Folder"
  445. F2 = Instance.new("Folder", F1)
  446. F2.Name = "Effects"
  447. Triangle = function(a, b, c)
  448. end
  449.  
  450. MagicBlock = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  451. local prt = part(3, F2, 0, 0, brickcolor, "Effect", vt())
  452. prt.Anchored = true
  453. prt.CanCollide = false
  454. prt.CFrame = cframe
  455. prt.Name = "prt"
  456. msh = mesh("BlockMesh", prt, "", "", vt(0, 0, 0), vt(x1, y1, z1))
  457. game:GetService("Debris"):AddItem(prt, 5)
  458. table.insert(Effects, {prt, "Block1", delay, x3, y3, z3})
  459. end
  460.  
  461.  
  462.  
  463. MagicCircle = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  464. local prt = part(3, F2, 0, 0, brickcolor, "Effect", vt())
  465. prt.Anchored = true
  466. prt.CanCollide = false
  467. prt.CFrame = cframe
  468. prt.Name = "prt"
  469. local msh = mesh("SpecialMesh", prt, "Sphere", "", vt(0, 0, 0), vt(x1, y1, z1))
  470. game:GetService("Debris"):AddItem(prt, 5)
  471. table.insert(Effects, {prt, "Cylinder", delay, x3, y3, z3})
  472. end
  473.  
  474. MagicWave = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  475. local prt = part(3, F2, 0, 0, brickcolor, "Effect", vt())
  476. prt.Anchored = true
  477. prt.CFrame = cframe
  478. local msh = mesh("SpecialMesh", prt, "FileMesh", "http://www.roblox.com/asset/?id=20329976", vt(0, 0, 0), vt(x1, y1, z1))
  479. game:GetService("Debris"):AddItem(prt, 5)
  480. table.insert(Effects, {prt, "Cylinder", delay, x3, y3, z3})
  481. end
  482.  
  483. MagicCylinder = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  484. local prt = part(3, F2, 0, 0, brickcolor, "Effect", vt(0.2, 0.2, 0.2))
  485. prt.Anchored = true
  486. prt.CFrame = cframe
  487. msh = mesh("SpecialMesh", prt, "Head", "", vt(0, 0, 0), vt(x1, y1, z1))
  488. game:GetService("Debris"):AddItem(prt, 5)
  489. Effects[#Effects + 1] = {prt, "Cylinder", delay, x3, y3, z3}
  490. end
  491.  
  492. MagicCylinder2 = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  493. local prt = part(3, F2, 0, 0, brickcolor, "Effect", vt(0.2, 0.2, 0.2))
  494. prt.Anchored = true
  495. prt.CFrame = cframe
  496. msh = mesh("CylinderMesh", prt, "", "", vt(0, 0, 0), vt(x1, y1, z1))
  497. game:GetService("Debris"):AddItem(prt, 5)
  498. Effects[#Effects + 1] = {prt, "Cylinder", delay, x3, y3, z3}
  499. end
  500.  
  501. MagicBlood = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  502. local prt = part(3, F2, 0, 0, brickcolor, "Effect", vt())
  503. prt.Anchored = true
  504. prt.CFrame = cframe
  505. local msh = mesh("SpecialMesh", prt, "Sphere", "", vt(0, 0, 0), vt(x1, y1, z1))
  506. game:GetService("Debris"):AddItem(prt, 5)
  507. table.insert(Effects, {prt, "Blood", delay, x3, y3, z3})
  508. end
  509.  
  510. ElecEffect = function(cff, x, y, z)
  511. local prt = part(3, F2, 0, 0, BrickColor.new("Dark indigo"), "Part", vt(1, 1, 1))
  512. prt.Anchored = true
  513. prt.CFrame = cff * cf(math.random(-x, x), math.random(-y, y), math.random(-z, z))
  514. prt.CFrame = cf(prt.Position)
  515. game:GetService("Debris"):AddItem(prt, 2)
  516. xval = math.random() / 2
  517. yval = math.random() / 2
  518. zval = math.random() / 2
  519. msh = mesh("BlockMesh", prt, "", "", vt(0, 0, 0), vt(xval, yval, zval))
  520. Effects[#Effects + 1] = {prt, "Elec", 0.1, x, y, z, xval, yval, zval}
  521. end
  522.  
  523. function FindNearestTorso(Position, Distance, SinglePlayer)
  524. if SinglePlayer then
  525. return (SinglePlayer.Torso.CFrame.p - Position).magnitude < Distance
  526. end
  527. local List = {}
  528. for i, v in pairs(workspace:GetChildren()) do
  529. if v:IsA("Model") then
  530. if v:findFirstChild("Torso") then
  531. if v ~= Character then
  532. if (v.Torso.Position - Position).magnitude <= Distance then
  533. table.insert(List, v)
  534. end
  535. end
  536. end
  537. end
  538. end
  539. return List
  540. end
  541.  
  542.  
  543. function CreatePart(Parent, Material, Reflectance, Transparency, BColor, Name, Size)
  544. local Part = Create("Part"){
  545. Parent = Parent,
  546. Reflectance = Reflectance,
  547. Transparency = Transparency,
  548. CanCollide = false,
  549. Locked = true,
  550. BrickColor = BrickColor.new(tostring(BColor)),
  551. Name = Name,
  552. Size = Size,
  553. Material = Material,
  554. }
  555. RemoveOutlines(Part)
  556. return Part
  557. end
  558.  
  559. function CreateMesh(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  560. local Msh = Create(Mesh){
  561. Parent = Part,
  562. Offset = OffSet,
  563. Scale = Scale,
  564. }
  565. if Mesh == "SpecialMesh" then
  566. Msh.MeshType = MeshType
  567. Msh.MeshId = MeshId
  568. end
  569. return Msh
  570. end
  571.  
  572.  
  573.  
  574. function BlockEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type)
  575. local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  576. prt.Anchored = true
  577. prt.CFrame = cframe
  578. local msh = CreateMesh("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  579. game:GetService("Debris"):AddItem(prt, 10)
  580. if Type == 1 or Type == nil then
  581. table.insert(Effects, {
  582. prt,
  583. "Block1",
  584. delay,
  585. x3,
  586. y3,
  587. z3,
  588. msh
  589. })
  590. elseif Type == 2 then
  591. table.insert(Effects, {
  592. prt,
  593. "Block2",
  594. delay,
  595. x3,
  596. y3,
  597. z3,
  598. msh
  599. })
  600. end
  601. end
  602.  
  603. function SphereEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  604. local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  605. prt.Anchored = true
  606. prt.CFrame = cframe
  607. local msh = CreateMesh("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  608. game:GetService("Debris"):AddItem(prt, 10)
  609. table.insert(Effects, {
  610. prt,
  611. "Cylinder",
  612. delay,
  613. x3,
  614. y3,
  615. z3,
  616. msh
  617. })
  618. end
  619.  
  620. function RingEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay,material)
  621. local prt=CreatePart(workspace,material,0,0,brickcolor,"Effect",vt(.5,.5,.5))--part(3,workspace,"SmoothPlastic",0,0,brickcolor,"Effect",vt(0.5,0.5,0.5))
  622. prt.Anchored=true
  623. prt.CFrame=cframe
  624. msh=CreateMesh("SpecialMesh",prt,"FileMesh","http://www.roblox.com/asset/?id=3270017",vt(0,0,0),vt(x1,y1,z1))
  625. game:GetService("Debris"):AddItem(prt,2)
  626. coroutine.resume(coroutine.create(function(Part,Mesh,num)
  627. for i=0,1,delay do
  628. swait()
  629. Part.Transparency=i
  630. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  631. end
  632. Part.Parent=nil
  633. end),prt,msh,(math.random(0,1)+math.random())/5)
  634. end
  635.  
  636. function CylinderEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  637. local prt = CreatePart(workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  638. prt.Anchored = true
  639. prt.CFrame = cframe
  640. local msh = CreateMesh("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  641. game:GetService("Debris"):AddItem(prt, 10)
  642. table.insert(Effects, {
  643. prt,
  644. "Cylinder",
  645. delay,
  646. x3,
  647. y3,
  648. z3,
  649. msh
  650. })
  651. end
  652.  
  653. function WaveEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  654. local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  655. prt.Anchored = true
  656. prt.CFrame = cframe
  657. local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "rbxassetid://20329976", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  658. game:GetService("Debris"):AddItem(prt, 10)
  659. table.insert(Effects, {
  660. prt,
  661. "Cylinder",
  662. delay,
  663. x3,
  664. y3,
  665. z3,
  666. msh
  667. })
  668. end
  669.  
  670. function SpecialEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  671. local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  672. prt.Anchored = true
  673. prt.CFrame = cframe
  674. local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "rbxassetid://24388358", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  675. game:GetService("Debris"):AddItem(prt, 10)
  676. table.insert(Effects, {
  677. prt,
  678. "Cylinder",
  679. delay,
  680. x3,
  681. y3,
  682. z3,
  683. msh
  684. })
  685. end
  686.  
  687.  
  688. function MoonEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  689. local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  690. prt.Anchored = true
  691. prt.CFrame = cframe
  692. local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "rbxassetid://259403370", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  693. game:GetService("Debris"):AddItem(prt, 10)
  694. table.insert(Effects, {
  695. prt,
  696. "Cylinder",
  697. delay,
  698. x3,
  699. y3,
  700. z3,
  701. msh
  702. })
  703. end
  704.  
  705. function HeadEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  706. local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  707. prt.Anchored = true
  708. prt.CFrame = cframe
  709. local msh = CreateMesh("SpecialMesh", prt, "Head", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  710. game:GetService("Debris"):AddItem(prt, 10)
  711. table.insert(Effects, {
  712. prt,
  713. "Cylinder",
  714. delay,
  715. x3,
  716. y3,
  717. z3,
  718. msh
  719. })
  720. end
  721.  
  722. function BreakEffect(brickcolor, cframe, x1, y1, z1)
  723. local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
  724. prt.Anchored = true
  725. prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  726. local msh = CreateMesh("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  727. local num = math.random(10, 50) / 1000
  728. game:GetService("Debris"):AddItem(prt, 10)
  729. table.insert(Effects, {
  730. prt,
  731. "Shatter",
  732. num,
  733. prt.CFrame,
  734. math.random() - math.random(),
  735. 0,
  736. math.random(50, 100) / 100
  737. })
  738. end
  739.  
  740. local lerp = function(a, b, t)
  741. return a * (1 - t) + b * t
  742. end
  743.  
  744. function clerp(a,b,t)
  745. local qa = {QuaternionFromCFrame(a)}
  746. local qb = {QuaternionFromCFrame(b)}
  747. local ax, ay, az = a.x, a.y, a.z
  748. local bx, by, bz = b.x, b.y, b.z
  749. local _t = 1-t
  750. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  751. end
  752.  
  753. function QuaternionFromCFrame(cf)
  754. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  755. local trace = m00 + m11 + m22
  756. if trace > 0 then
  757. local s = math.sqrt(1 + trace)
  758. local recip = 0.5/s
  759. return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
  760. else
  761. local i = 0
  762. if m11 > m00 then
  763. i = 1
  764. end
  765. if m22 > (i == 0 and m00 or m11) then
  766. i = 2
  767. end
  768. if i == 0 then
  769. local s = math.sqrt(m00-m11-m22+1)
  770. local recip = 0.5/s
  771. return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
  772. elseif i == 1 then
  773. local s = math.sqrt(m11-m22-m00+1)
  774. local recip = 0.5/s
  775. return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
  776. elseif i == 2 then
  777. local s = math.sqrt(m22-m00-m11+1)
  778. local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
  779. end
  780. end
  781. end
  782.  
  783.  
  784. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  785. local xs, ys, zs = x + x, y + y, z + z
  786. local wx, wy, wz = w*xs, w*ys, w*zs
  787. local xx = x*xs
  788. local xy = x*ys
  789. local xz = x*zs
  790. local yy = y*ys
  791. local yz = y*zs
  792. local zz = z*zs
  793. return CFrame.new(px, py, pz,1-(yy+zz), xy - wz, xz + wy,xy + wz, 1-(xx+zz), yz - wx, xz - wy, yz + wx, 1-(xx+yy))
  794. end
  795. function QuaternionSlerp(a, b, t)
  796. local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
  797. local startInterp, finishInterp;
  798. if cosTheta >= 0.0001 then
  799. if (1 - cosTheta) > 0.0001 then
  800. local theta = math.acos(cosTheta)
  801. local invSinTheta = 1/math.sin(theta)
  802. startInterp = math.sin((1-t)*theta)*invSinTheta
  803. finishInterp = math.sin(t*theta)*invSinTheta
  804. else
  805. startInterp = 1-t
  806. finishInterp = t
  807. end
  808. else
  809. if (1+cosTheta) > 0.0001 then
  810. local theta = math.acos(-cosTheta)
  811. local invSinTheta = 1/math.sin(theta)
  812. startInterp = math.sin((t-1)*theta)*invSinTheta
  813. finishInterp = math.sin(t*theta)*invSinTheta
  814. else
  815. startInterp = t-1
  816. finishInterp = t
  817. end
  818. end
  819. return a[1]*startInterp + b[1]*finishInterp, a[2]*startInterp + b[2]*finishInterp, a[3]*startInterp + b[3]*finishInterp, a[4]*startInterp + b[4]*finishInterp
  820. end
  821.  
  822. function weld5(part0, part1, c0, c1)
  823. weeld=Instance.new("Weld", part0)
  824. weeld.Part0=part0
  825. weeld.Part1=part1
  826. weeld.C0=c0
  827. weeld.C1=c1
  828. return weeld
  829. end
  830.  
  831. --Example: Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4)
  832.  
  833. function rayCast(Pos, Dir, Max, Ignore) -- Origin Position , Direction, MaxDistance , IgnoreDescendants
  834. return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
  835. end
  836.  
  837.  
  838.  
  839.  
  840.  
  841.  
  842. Character.Humanoid.MaxHealth = 120
  843. Character.Humanoid.Health = 120
  844.  
  845. local f = 0
  846. local b = Instance.new("BlurEffect",cam)
  847. local c = Instance.new('PointLight', Torso)
  848. c.Range = 16
  849. c.Color = Color3.new(0, 1,1)
  850. c.Brightness = 1.5
  851. game:GetService("RunService"):BindToRenderStep("W0tT", 0, function()
  852.  
  853. b.Size = b.Size - 4
  854. if boost == true then
  855. c.Enabled = true
  856. cam.FieldOfView = lerp(cam.FieldOfView, 110, 0.5)
  857. -- cam.FieldOfView = 110
  858. freefall = 0
  859. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0,0,3),0.25)
  860. SphereEffect(BrickColor.new("Cyan"),RightLeg.CFrame*CFrame.new(0,-1,0)*angles(math.random(-180,180),math.random(-180,180),math.random(-180,180)),1.4,12,1.4,2.8,26,2.8,0.07)
  861. SphereEffect(BrickColor.new("Cyan"),LeftLeg.CFrame*CFrame.new(0,-1,0)*angles(math.random(-180,180),math.random(-180,180),math.random(-180,180)),1.4,12,1.4,2.8,26,2.8,0.07)
  862. if hitfloor ~= nil and Anim ~= "runIdle" then
  863. SpecialEffect(BrickColor.new("Cyan"),RootPart.CFrame*CFrame.new(0,-3.4,.78) ,2,2,2, 1.5,1.5,1.5,.09)
  864. end
  865. end
  866. if boost == false then
  867. cam.FieldOfView = lerp(cam.FieldOfView, 70, 0.076)
  868. --cam.FieldOfView = 70
  869. c.Enabled = false
  870. end
  871. end)
  872.  
  873.  
  874.  
  875. mouse.KeyDown:connect(function(key)
  876. if string.byte(key) == 48 then
  877. b.Size = 40
  878. Swing = 2
  879. freefall = 0
  880.  
  881. coroutine.resume(coroutine.create(function()
  882. for i = 0,1,0.1 do
  883. swait()
  884. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(math.random(-0.35*1.8,0.35*1.8),math.random(-0.35*1.8,0.35*1.8),math.random(-0.35*1.8,0.35*1.8)),0.24)
  885. end
  886. end))
  887. Humanoid.WalkSpeed = 180
  888. RootPart.Velocity = RootPart.CFrame.lookVector*150
  889. RingEffect(BrickColor.new("Cyan"), RootPart.CFrame*CFrame.new(0,0,-9.2) , 1, 1, 1, 8, 8, 8, 0.14,"Neon")
  890. boost = true
  891. boostsound:Play()
  892. end
  893. end)
  894.  
  895. mouse.KeyUp:connect(function(key)
  896. if string.byte(key) == 48 then
  897. Swing = 1
  898. Humanoid.WalkSpeed = 64
  899. boost = false
  900. boostsound:Stop()
  901.  
  902. end
  903. end)
  904.  
  905.  
  906.  
  907.  
  908. mouse.KeyDown:connect(function(key)
  909. if string.byte(key) == 50 then
  910. b.Size = 40
  911. freefall = 0
  912. Swing = 2
  913.  
  914. coroutine.resume(coroutine.create(function()
  915. for i = 0,1,0.1 do
  916. swait()
  917. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(math.random(-0.35*2.8,0.35*2.8),math.random(-0.35*2.8,0.35*2.8),math.random(-0.35*2.8,0.35*2.8)),0.48)
  918. end
  919. end))
  920.  
  921. Humanoid.WalkSpeed = 320
  922. RootPart.Velocity = RootPart.CFrame.lookVector*550
  923. RingEffect(BrickColor.new("Cyan"), RootPart.CFrame*CFrame.new(0,0,-9.2) , 1, 1, 1, 18, 18, 18, 0.14,"Neon")
  924. RingEffect(BrickColor.new("White"), RootPart.CFrame*CFrame.new(0,0,-11.2) , 1, 1, 1, 18, 18, 18, 0.14,"Neon")
  925. RingEffect(BrickColor.new("Cyan"), RootPart.CFrame*CFrame.new(0,0,-13.2) , 1, 1, 1, 18, 18, 18, 0.14,"Neon")
  926. boost = true
  927. boostsound:Play()
  928. end
  929. end)
  930.  
  931. mouse.KeyUp:connect(function(key)
  932. if string.byte(key) == 50 then
  933. Swing = 1
  934. Humanoid.WalkSpeed = 64
  935. boost = false
  936. boostsound:Stop()
  937.  
  938. end
  939. end)
  940.  
  941.  
  942. local lastwall = nil
  943. local jumped = false
  944.  
  945.  
  946.  
  947.  
  948.  
  949.  
  950. local vwall = false
  951.  
  952. mouse.KeyDown:connect(function(key)
  953. if key == 'b' and hitfloor == nil and attack == false then
  954. vrun()
  955. end
  956. end)
  957.  
  958.  
  959. function vrun()
  960. local ray = Ray.new(
  961. RootPart.CFrame.p, RootPart.CFrame.lookVector *2.5
  962. )
  963. local hit, position, normal = workspace:FindPartOnRay(ray, character)
  964.  
  965. if hit then
  966. if hit.Parent.Parent ~= Character and hit.Parent ~= Character and hit.Name ~= "prt" and hit.CanCollide == true then
  967. vwall = true
  968. local NV = Vector3.new(0,0,0)
  969. local spd = Vector3.new(RootPart.Velocity.x,0,RootPart.Velocity.z).magnitude + 10
  970. local dir = Vector3.new(RootPart.Velocity.x,0,RootPart.Velocity.z).unit
  971. local GravPoint = RootPart.Velocity.y
  972. local velo = Instance.new("BodyVelocity",Torso)
  973. velo.MaxForce = Vector3.new(400000,400000,400000)
  974.  
  975. attack = true
  976. while vwall == true and ray and hit do
  977. swait()
  978. change = 0.84+ Humanoid.WalkSpeed/132
  979. if Humanoid.WalkSpeed > 40 and Humanoid.WalkSpeed < 70 then
  980. velo.Velocity = Vector3.new(0,40,0)
  981. end
  982. if Humanoid.WalkSpeed > 70 and Humanoid.WalkSpeed < 200 then
  983. velo.Velocity = Vector3.new(0,80,0)
  984. end
  985. if Humanoid.WalkSpeed > 200 then
  986. velo.Velocity = Vector3.new(0,130,0)
  987. end
  988. ray = Ray.new(
  989. RootPart.CFrame.p, RootPart.CFrame.lookVector *2.5
  990. )
  991. hit, position, normal = workspace:FindPartOnRay(ray, character)
  992. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1-0.52*math.cos(sine/2), .6) * angles(math.rad(96), math.rad(0), math.rad(0)+ RootPart.RotVelocity.Y / 26), .1)
  993. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-11+20*math.sin(sine/2)),math.rad(0),math.rad(0+5*math.sin(sine/4)) + RootPart.RotVelocity.Y / 13),.1)
  994. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0.1) * angles(math.rad(-90-7*math.sin(sine/4))+ RootPart.RotVelocity.Y / -34, math.rad(0), math.rad(15+2*math.sin(sine/4))- RootPart.RotVelocity.Y / 34),.15)
  995. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0.1)*angles(math.rad(-90-7*math.sin(sine/4))+ RootPart.RotVelocity.Y / 34,math.rad(0),math.rad(-15+2*math.sin(sine/4))+ RootPart.RotVelocity.Y / -34),.15)
  996. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1+0.28*math.cos(sine/4), 0-0.32*math.cos(sine/4)) * CFrame.Angles(math.rad(0+104*math.sin(sine/4)), math.rad(0)+ RootPart.RotVelocity.Y / 42, math.rad(0)+ RootPart.RotVelocity.Y / -54), 0.3+ Humanoid.WalkSpeed/272)
  997. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1-0.28*math.cos(sine/4),0+0.32*math.cos(sine/4)) * CFrame.Angles(math.rad(0-104*math.sin(sine/4)), math.rad(0)+ RootPart.RotVelocity.Y / 42, math.rad(0)- RootPart.RotVelocity.Y / 54), 0.3+ Humanoid.WalkSpeed/272)
  998. end
  999. velo:Destroy()
  1000. wait(0.07)
  1001.  
  1002. if vwall == false then
  1003.  
  1004. RootPart.Velocity = -RootPart.CFrame.lookVector*68 + Vector3.new(0,86,0)
  1005.  
  1006. --[[]
  1007. for i = 0,5,0.2 do
  1008. rs:wait()
  1009. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -0.79, 0) * CFrame.Angles(math.rad(0+100*i), math.rad(0), math.rad(0)), 0.2)
  1010. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(20),math.rad(0),math.rad(0)),.2)
  1011. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(180), math.rad(-60), math.rad(40)),.2)
  1012. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(180), math.rad(60), math.rad(-40)),.2)
  1013. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.2)
  1014. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.2)
  1015. end
  1016. ]]
  1017.  
  1018.  
  1019. for i = 0,4,0.1 do
  1020. swait()
  1021. Humanoid.CameraOffset = Vector3.new(0,0,0)
  1022. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0+260*i), math.rad(0), math.rad(0)), 0.6)
  1023. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(70),math.rad(0),math.rad(0)),.1)
  1024. RW.C0 = clerp(RW.C0, CFrame.new(.7, -0.22, -0.5) * angles(math.rad(90), math.rad(0), math.rad(-90)), 0.1)
  1025. LW.C0 = clerp(LW.C0, CFrame.new(-.7, -0.22, -0.5) * angles(math.rad(90), math.rad(0), math.rad(90)), 0.1)
  1026. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -.34, -0.7) * CFrame.Angles(math.rad(-25), math.rad(0), math.rad(0)), 0.1)
  1027. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -.34, -0.7) * CFrame.Angles(math.rad(-25), math.rad(0), math.rad(0)), 0.1)
  1028. end
  1029.  
  1030. attack = false
  1031.  
  1032.  
  1033. end
  1034.  
  1035.  
  1036. if vwall == true then
  1037. RootPart.Velocity = RootPart.CFrame.lookVector*38 + Vector3.new(0,86,0)
  1038.  
  1039. --[[]
  1040. for i = 0,5,0.2 do
  1041. rs:wait()
  1042. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -0.79, 0) * CFrame.Angles(math.rad(0+100*i), math.rad(0), math.rad(0)), 0.2)
  1043. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(20),math.rad(0),math.rad(0)),.2)
  1044. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(180), math.rad(-60), math.rad(40)),.2)
  1045. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(180), math.rad(60), math.rad(-40)),.2)
  1046. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.2)
  1047. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.2)
  1048. end
  1049. ]]
  1050.  
  1051.  
  1052. for i = 0,4,0.15 do
  1053. swait()
  1054. Humanoid.CameraOffset = Vector3.new(0,0,0)
  1055. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0-260*i), math.rad(0), math.rad(0)), 0.6)
  1056. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(70),math.rad(0),math.rad(0)),.1)
  1057. RW.C0 = clerp(RW.C0, CFrame.new(.7, -0.22, -0.5) * angles(math.rad(90), math.rad(0), math.rad(-90)), 0.1)
  1058. LW.C0 = clerp(LW.C0, CFrame.new(-.7, -0.22, -0.5) * angles(math.rad(90), math.rad(0), math.rad(90)), 0.1)
  1059. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -.34, -0.7) * CFrame.Angles(math.rad(-25), math.rad(0), math.rad(0)), 0.1)
  1060. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -.34, -0.7) * CFrame.Angles(math.rad(-25), math.rad(0), math.rad(0)), 0.1)
  1061. end
  1062.  
  1063. attack = false
  1064.  
  1065. end
  1066.  
  1067.  
  1068. end
  1069. end
  1070. end
  1071.  
  1072.  
  1073.  
  1074.  
  1075. mouse.KeyUp:connect(function(key)
  1076. if key == 'b' and vwall == true then
  1077. vwall = false
  1078. end
  1079. end)
  1080.  
  1081.  
  1082.  
  1083.  
  1084.  
  1085. function Ldash()
  1086.  
  1087.  
  1088.  
  1089. evadecooldown = true
  1090. attack = true
  1091. k = math.random(1,2)
  1092. if k == 1 then
  1093. so("http://www.roblox.com/asset/?id=807766310", Head, 2.5, 1)
  1094. else
  1095. so("http://www.roblox.com/asset/?id=807768137", Head, 2.5, 1)
  1096. end
  1097.  
  1098.  
  1099.  
  1100.  
  1101.  
  1102. --+173.8*i
  1103. for i = 0,.7,0.1 do
  1104. swait()
  1105. Head.Velocity = Head.CFrame.rightVector * -135
  1106. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(32)), 0.2)
  1107. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0),math.rad(-9),math.rad(-14)),.2)
  1108. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, -0.2) * angles(math.rad(27), math.rad(0), math.rad(30)),.2)
  1109. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(30), math.rad(0), math.rad(30)),.2)
  1110. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(12)), 0.2)
  1111. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(8)), 0.2)
  1112. end
  1113.  
  1114. attack = false
  1115. wait(0.08)
  1116. evadecooldown = false
  1117.  
  1118.  
  1119. end
  1120.  
  1121.  
  1122.  
  1123.  
  1124.  
  1125. function Rdash()
  1126.  
  1127.  
  1128.  
  1129. evadecooldown = true
  1130. attack = true
  1131. k = math.random(1,2)
  1132. if k == 1 then
  1133. so("http://www.roblox.com/asset/?id=807766310", Head, 2.5, 1)
  1134. else
  1135. so("http://www.roblox.com/asset/?id=807768137", Head, 2.5, 1)
  1136. end
  1137.  
  1138.  
  1139.  
  1140.  
  1141.  
  1142. --+173.8*i
  1143. for i = 0,.7,0.1 do
  1144. swait()
  1145. Head.Velocity = Head.CFrame.rightVector * 135
  1146. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(-32)), 0.2)
  1147. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0),math.rad(9),math.rad(14)),.2)
  1148. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(30), math.rad(0), math.rad(-30)),.2)
  1149. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, -0.2) * angles(math.rad(27), math.rad(0), math.rad(-30)),.2)
  1150. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(-8)), 0.2)
  1151. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(-12)), 0.2)
  1152. end
  1153.  
  1154. attack = false
  1155. wait(0.08)
  1156. evadecooldown = false
  1157.  
  1158.  
  1159. end
  1160. local sliding = false
  1161.  
  1162.  
  1163. function Slide()
  1164.  
  1165. local spd = Vector3.new(RootPart.Velocity.x,0,RootPart.Velocity.z).magnitude + 10
  1166. spd = spd + 30
  1167. local dir = Vector3.new(RootPart.Velocity.x,0,RootPart.Velocity.z).unit
  1168. local GravPoint = RootPart.Velocity.y
  1169. if spd > 40 and hitfloor ~= nil then
  1170. noleg = true
  1171.  
  1172. attack = true
  1173. k = math.random(1,2)
  1174. if k == 1 then
  1175. so("http://www.roblox.com/asset/?id=807766310", Head, 2.5, 1)
  1176. else
  1177. so("http://www.roblox.com/asset/?id=807768137", Head, 2.5, 1)
  1178. end
  1179.  
  1180.  
  1181.  
  1182.  
  1183.  
  1184.  
  1185.  
  1186.  
  1187.  
  1188.  
  1189. local NV = Vector3.new(0,0,0)
  1190. local bv = Instance.new("BodyVelocity", Torso)
  1191. bv.maxForce = Vector3.new(1/0,1/0,1/0)
  1192. bv.velocity = dir*spd
  1193. local bg = Instance.new("BodyGyro", Torso)
  1194. bg.maxTorque = Vector3.new(1/0,1/0,1/0)
  1195. bg.cframe = CFrame.new(NV, dir) * CFrame.Angles(math.pi/2.2,0.24,0)
  1196. Head.Running.SoundId = "rbxassetid://1295468446"
  1197. Head.Running.TimePosition = 0
  1198.  
  1199. Humanoid.PlatformStand = true
  1200. while spd > 2 and hitfloor ~= nil and sliding == true do
  1201. swait()
  1202. spd = spd - 0.95
  1203. bv.velocity = dir*spd + Vector3.new(0,0,0)
  1204. bg.cframe = CFrame.new(NV, dir) * CFrame.Angles(math.pi/2.2,0.24,0)
  1205. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -2.3, 0) * CFrame.Angles(math.rad(90), math.rad(0), math.rad(12)), 0.2)
  1206. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(34),math.rad(0),math.rad(12)),.2)
  1207. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(110), math.rad(0), math.rad(70)),.2)
  1208. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, -0.2) * angles(math.rad(0), math.rad(0), math.rad(-60)),.2)
  1209. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.2)
  1210. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -0.56, -0.2) * CFrame.Angles(math.rad(-24), math.rad(0), math.rad(0)), 0.2)
  1211. end
  1212. bv:Destroy()
  1213. bg:Destroy()
  1214. Head.Running.SoundId = "rbxassetid://758199523"
  1215. Head.Running.TimePosition = 0
  1216. Humanoid.PlatformStand = false
  1217. attack = false
  1218. sliding = false
  1219. wait(0.05)
  1220. evadecooldown = false
  1221.  
  1222.  
  1223. end
  1224. end
  1225.  
  1226. function land()
  1227. attack = true
  1228. RootPart.Velocity = Vector3.new(0,0,0)
  1229. WaveEffect(BrickColor.new("Cyan"), RootPart.CFrame*CFrame.new(0,-1,0) , 1, 1, 1, 3, 0.8, 3, 0.06)
  1230. so("http://www.roblox.com/asset/?id=1295424585", Torso, 3.5, 1)
  1231.  
  1232. coroutine.resume(coroutine.create(function()
  1233. for i = 0,1,0.1 do
  1234. swait()
  1235. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(math.random(-0.55*2.8,0.55*2.8),math.random(-0.55*2.8,0.55*2.8),math.random(-0.55*2.8,0.55*2.8)),0.44)
  1236. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -2, 0) * CFrame.Angles(math.rad(-16), math.rad(0), math.rad(0)), 0.5)
  1237. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(7),math.rad(0),math.rad(0)),.5)
  1238. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(87)),.5)
  1239. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, -0) * angles(math.rad(0), math.rad(0), math.rad(-87)),.5)
  1240. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, 0, -0.5) * CFrame.Angles(math.rad(16), math.rad(0), math.rad(0)), 0.5)
  1241. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1.14, 0.2) * CFrame.Angles(math.rad(-17), math.rad(0), math.rad(0)), 0.5)
  1242.  
  1243. end
  1244. attack = false
  1245.  
  1246.  
  1247. end))
  1248.  
  1249.  
  1250.  
  1251. end
  1252.  
  1253.  
  1254.  
  1255.  
  1256. function stomp()
  1257. attack = true
  1258. stompsound:Play()
  1259.  
  1260. while hitfloor == nil do
  1261. swait()
  1262. b.Size = 12
  1263. WaveEffect(BrickColor.new("Cyan"), LeftLeg.CFrame*CFrame.new(0,-2.4,0) , 1, 1, 1, 0.8, 0.8, 0.8, 0.14)
  1264. RootPart.Velocity = Vector3.new(0,RootPart.Velocity.y/1.6,0) +Vector3.new(0,-150,0)
  1265. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0,0,0),0.15)
  1266. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0.2) * CFrame.Angles(math.rad(0+4*math.sin(sine/1.3)), math.rad(0), math.rad(0)),0.07)
  1267. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.65, 0) * angles(math.rad(0), math.rad(0), math.rad(140+12*math.cos(sine/1.3))), 0.07)
  1268. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.65, 0) * angles(math.rad(0), math.rad(0), math.rad(-140+12*math.cos(sine/1.3))), 0.07)
  1269. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(60+7*math.sin(sine/1.3)),math.rad(0),math.rad(0)),0.07)
  1270. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1+0.17*math.cos(sine/1.3), -0.13) * CFrame.Angles(math.rad(0+4*math.cos(sine/1.3)), math.rad(3), math.rad(0)), 0.1)
  1271. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, .27+0.17*math.cos(sine/1.3), -0.56) * CFrame.Angles(math.rad(-12+4*math.cos(sine/1.3)), math.rad(0), math.rad(0)), 0.1)
  1272.  
  1273. end
  1274. stompsound:Stop()
  1275. land()
  1276.  
  1277.  
  1278. end
  1279.  
  1280.  
  1281. function changemusic()
  1282. musicnum = musicnum + 1
  1283. music.TimePosition = 0
  1284. local osix = false
  1285. local spd = Vector3.new(RootPart.Velocity.x,0,RootPart.Velocity.z).magnitude
  1286. if musicnum > 14 then
  1287. musicnum = 1
  1288. end
  1289. if musicnum == 1 then
  1290. music.SoundId = "rbxassetid://179029173"
  1291. end
  1292. if musicnum == 2 then
  1293. music.SoundId = "rbxassetid://146443855"
  1294. end
  1295. if musicnum == 3 then
  1296. music.SoundId = "rbxassetid://1342408291"
  1297. end
  1298. if musicnum == 4 then
  1299. music.SoundId = "rbxassetid://201219416"
  1300. end
  1301. if musicnum == 5 then
  1302. music.SoundId = "rbxassetid://1390472571"
  1303. end
  1304. if musicnum == 6 then
  1305. osix = true
  1306. music.SoundId = "rbxassetid://249974783"
  1307. end
  1308. if musicnum == 7 then
  1309. music.SoundId = "rbxassetid://1851880603"
  1310. end
  1311. if musicnum == 8 then
  1312. music.SoundId = "rbxassetid://412034984"
  1313. end
  1314. if musicnum == 9 then
  1315. music.SoundId = "rbxassetid://536915629"
  1316. end
  1317. if musicnum == 10 then
  1318. music.SoundId = "rbxassetid://1200005861"
  1319. end
  1320. if musicnum == 11 then
  1321. music.SoundId = "rbxassetid://1055930631"
  1322. end
  1323. if musicnum == 12 then
  1324. music.SoundId = "rbxassetid://300269553"
  1325. end
  1326. if musicnum == 13 then
  1327. music.SoundId = "rbxassetid://199897052"
  1328. end
  1329. if musicnum == 14 then
  1330. music.SoundId = "rbxassetid://638115895"
  1331. end
  1332.  
  1333. if spd < 14 then
  1334. Humanoid.Jump = true
  1335.  
  1336. if osix == false then
  1337. so("rbxassetid://537371462",PlayerGui,2,1)
  1338. end
  1339.  
  1340.  
  1341. RootPart.Velocity = Vector3.new(0,102,0)
  1342. attack = true
  1343. wait(0.08)
  1344. for i = 0,7,0.1 do
  1345. swait()
  1346. RootPart.Velocity = Vector3.new(0,2,0)
  1347. Humanoid.CameraOffset = Vector3.new(0,0,0)
  1348. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0-260*i), math.rad(0), math.rad(0)), 0.6)
  1349. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(70),math.rad(0),math.rad(0)),.1)
  1350. RW.C0 = clerp(RW.C0, CFrame.new(.7, -0.22, -0.5) * angles(math.rad(90), math.rad(0), math.rad(-90)), 0.1)
  1351. LW.C0 = clerp(LW.C0, CFrame.new(-.7, -0.22, -0.5) * angles(math.rad(90), math.rad(0), math.rad(90)), 0.1)
  1352. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -.34, -0.7) * CFrame.Angles(math.rad(-25), math.rad(0), math.rad(0)), 0.1)
  1353. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -.34, -0.7) * CFrame.Angles(math.rad(-25), math.rad(0), math.rad(0)), 0.1)
  1354.  
  1355. end
  1356. b.Size = 40
  1357. MoonEffect(BrickColor.new("Cyan"), RootPart.CFrame*CFrame.new(0,0,0) , 1, 1, 1, 8, 8, 8, 0.06)
  1358.  
  1359. if osix == true then
  1360. osix = false
  1361. so("rbxassetid://156821036",PlayerGui,2,1)
  1362. end
  1363.  
  1364. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -3, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 1)
  1365. for i = 0,5,0.1 do
  1366. swait()
  1367. RootPart.Velocity = Vector3.new(0,3.5,0)
  1368. Humanoid.CameraOffset = Vector3.new(0,0,0)
  1369. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1+0.1*i, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.21)
  1370. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(22-2*i),math.rad(0),math.rad(0)),.21)
  1371. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5+0.09*i, 0) * angles(math.rad(20-6*i), math.rad(0), math.rad(90+13*i)), 0.21)
  1372. LW.C0 = clerp(LW.C0, CFrame.new(-1.0-0.12*i, 0.5, -0.4+0.05*i) * angles(math.rad(20+13*i), math.rad(0), math.rad(20-13*i)), 0.21)
  1373. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(45+6*i), math.rad(0), math.rad(-22-4*i)), 0.21)
  1374. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(45+6*i), math.rad(0), math.rad(22+4*i)), 0.21)
  1375. end
  1376. attack = false
  1377. end
  1378. end
  1379.  
  1380.  
  1381. mouse.KeyDown:connect(function(key)
  1382. if key == 'q' and attack == false and evadecooldown == false then
  1383. Ldash()
  1384. end
  1385. end)
  1386.  
  1387.  
  1388.  
  1389. mouse.KeyDown:connect(function(key)
  1390. if key == 'e' and attack == false and evadecooldown == false then
  1391. Rdash()
  1392. end
  1393. end)
  1394.  
  1395. mouse.KeyDown:connect(function(key)
  1396. if key == 'c' and attack == false and evadecooldown == false and hitfloor ~= nil then
  1397. sliding = true
  1398. Slide()
  1399. end
  1400. end)
  1401.  
  1402. mouse.KeyDown:connect(function(key)
  1403. if key == 'c' and attack == false and hitfloor == nil then
  1404. stomp()
  1405. end
  1406. end)
  1407.  
  1408.  
  1409. local walljump = false
  1410.  
  1411.  
  1412. function walljumpp()
  1413. local ray = Ray.new(
  1414. Torso.CFrame.p, RootPart.CFrame.lookVector *5
  1415. )
  1416. local hit, position, normal = workspace:FindPartOnRay(ray, character)
  1417.  
  1418. if hit then
  1419. if hit.Parent.Parent ~= Character and hit.Parent ~= Character then
  1420. local dir = Vector3.new(RootPart.Velocity.x,0,RootPart.Velocity.z).unit
  1421. GravPoint = 0
  1422. freefall = 0
  1423. walljump = true
  1424. Humanoid.AutoRotate = false
  1425. local velo = Instance.new("BodyVelocity",Torso)
  1426. velo.MaxForce = Vector3.new(400000,400000,400000)
  1427. --game.Debris:AddItem(velo,0.1)
  1428. attack = true
  1429. while hitfloor == nil and walljump == true and ray and hit do
  1430. swait()
  1431. freefall = 0
  1432. GravPoint = GravPoint - 0.36
  1433. ray = Ray.new(
  1434. RootPart.CFrame.p, RootPart.CFrame.lookVector *2.5
  1435. )
  1436. hit, position, normal = workspace:FindPartOnRay(ray, character)
  1437. velo.Velocity = vt(0,GravPoint,0)
  1438. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0.9) * CFrame.Angles(math.rad(5), math.rad(90), math.rad(8)), 0.2)
  1439. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(7),math.rad(0),math.rad(86)),.2)
  1440. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(120)),.2)
  1441. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-60)),.2)
  1442. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(-6), math.rad(14), math.rad(-12)), 0.2)
  1443. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(23)), 0.2)
  1444. end
  1445. if walljump == false then
  1446. k = math.random(1,3)
  1447. if k == 1 then
  1448. so("http://www.roblox.com/asset/?id=800121776", Head, 2.5, 1)
  1449. else if k == 2 then
  1450. so("http://www.roblox.com/asset/?id=804889329", Head, 2.5, 1)
  1451. else if k == 3 then
  1452. so("http://www.roblox.com/asset/?id=804907617", Head, 2.5, 1)
  1453. end
  1454. end
  1455. end
  1456.  
  1457. velo:Destroy()
  1458. attack = false
  1459. coroutine.resume(coroutine.create(function()
  1460. for i = 0,1,0.1 do
  1461. swait()
  1462. Humanoid.CameraOffset = Vector3.new(0,0,0)
  1463. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0+260*i), math.rad(0), math.rad(0)), 0.6)
  1464. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(70),math.rad(0),math.rad(0)),.1)
  1465. RW.C0 = clerp(RW.C0, CFrame.new(.7, -0.22, -0.5) * angles(math.rad(90), math.rad(0), math.rad(-90)), 0.1)
  1466. LW.C0 = clerp(LW.C0, CFrame.new(-.7, -0.22, -0.5) * angles(math.rad(90), math.rad(0), math.rad(90)), 0.1)
  1467. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -.34, -0.7) * CFrame.Angles(math.rad(-25), math.rad(0), math.rad(0)), 0.1)
  1468. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -.34, -0.7) * CFrame.Angles(math.rad(-25), math.rad(0), math.rad(0)), 0.1)
  1469. end
  1470. end))
  1471.  
  1472. Humanoid.AutoRotate = true
  1473. RootPart.Velocity = RootPart.CFrame.lookVector * -137 + Vector3.new(0,136,0)
  1474. wait(0.07)
  1475. RootPart.CFrame = CFrame.new(RootPart.CFrame.p,-RootPart.CFrame.lookVector)
  1476. end
  1477. if walljump == true then
  1478. attack = false
  1479. walljump = false
  1480. Humanoid.AutoRotate = true
  1481. velo:Destroy()
  1482. end
  1483. end
  1484. end
  1485. end
  1486.  
  1487.  
  1488. local homed = nil
  1489. function home()
  1490. if walljump ~= true then
  1491. for i, v in pairs(FindNearestTorso(Torso.CFrame.p, 80)) do
  1492. if v:FindFirstChild('Head') then
  1493. Grabbed = true
  1494. homed = v
  1495. end
  1496. end
  1497.  
  1498. if homed ~= nil and homed:FindFirstChildOfClass("Humanoid").Health > 1 and walljump == false then
  1499. so("http://www.roblox.com/asset/?id=162460823", Head, 1, .8)
  1500. local SBall = Instance.new("Part",Character)
  1501. SBall.Name = "Homing Ball"
  1502. SBall.CanCollide = false
  1503. SBall.Anchored = false
  1504. SBall.Transparency = 0.64
  1505. SBall.CFrame = CFrame.new(RootPart.CFrame.p)
  1506. SBall.BrickColor = BrickColor.new("Toothpaste")
  1507. SBall.Size = Vector3.new(1,1,1)
  1508. SBall.Material = "Neon"
  1509. SBallweld = Instance.new("Weld")
  1510. SBallweld.Parent = SBall
  1511. SBallweld.Part0 = RootPart
  1512. SBallweld.Part1 = SBall
  1513. SBallweld.C1 = CFrame.new(0, 1, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0))
  1514. SBallweld.Part0 = RootPart
  1515. local SBallmesh = Instance.new("SpecialMesh",SBall)
  1516. SBallmesh.MeshType = "Sphere"
  1517. SBallmesh.Scale = Vector3.new(6,6,6)
  1518. trail = Instance.new("Trail", Character)
  1519. a2 = Instance.new("Attachment", Torso) a2.Position = Vector3.new(0,2,0)
  1520. a3 = Instance.new("Attachment", Torso)a3.Position = Vector3.new(0,-2.5,0)
  1521. trail.Texture = "rbxassetid://0"
  1522. trail.Attachment0 = a2
  1523. trail.Attachment1 = a3
  1524. trail.Lifetime = 0.353
  1525. trail.MinLength = 0.03
  1526. trail.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,0,0),NumberSequenceKeypoint.new(1,1,1)})
  1527. trail.Color = ColorSequence.new(Color3.new(0,1,1), Color3.new(0, 0,0))
  1528. trail.LightEmission = 4.8
  1529. trail.TextureLength = 0.034
  1530. trail.Enabled = true
  1531. attack = true
  1532. local position = Instance.new("BodyPosition",Torso)
  1533. position.P = 68350
  1534. position.maxForce = Vector3.new(math.huge,math.huge,math.huge)
  1535.  
  1536. while homed ~= nil and (homed.Torso.Position-RootPart.Position).magnitude > 8 do
  1537. swait()
  1538. SBall.CFrame = CFrame.new(RootPart.CFrame.p)
  1539. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0+420*math.abs(sine/3.2)), math.rad(0), math.rad(0)), 0.6)
  1540. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(70),math.rad(0),math.rad(0)),.1)
  1541. RW.C0 = clerp(RW.C0, CFrame.new(.7, -0.22, -0.5) * angles(math.rad(90), math.rad(0), math.rad(-90)), 0.1)
  1542. LW.C0 = clerp(LW.C0, CFrame.new(-.7, -0.22, -0.5) * angles(math.rad(90), math.rad(0), math.rad(90)), 0.1)
  1543. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -.34, -0.7) * CFrame.Angles(math.rad(-25), math.rad(0), math.rad(0)), 0.1)
  1544. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -.34, -0.7) * CFrame.Angles(math.rad(-25), math.rad(0), math.rad(0)), 0.1)
  1545. position.Position = homed.Torso.Position + Vector3.new(0,2,0)
  1546. end
  1547. local bodvol=Instance.new("BodyVelocity")
  1548. bodvol.velocity= RootPart.CFrame.lookVector*240 + Vector3.new(0,30,0)
  1549. bodvol.P= 35200
  1550. bodvol.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  1551. bodvol.Parent=homed.Head
  1552. game:GetService("Debris"):AddItem(bodvol, 0.2)
  1553. homed:FindFirstChildOfClass("Humanoid"):TakeDamage(math.random(10,30))
  1554.  
  1555. position:Destroy()
  1556. trail.Enabled = false
  1557. SBall:Destroy()
  1558. RootPart.Velocity = Vector3.new(0,93.5,0)
  1559. coroutine.resume(coroutine.create(function()
  1560. for i = 0,5,0.26 do
  1561. swait()
  1562. Humanoid.CameraOffset = Vector3.new(0,0,0)
  1563. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1+0.1*i, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.21)
  1564. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(22-2*i),math.rad(0),math.rad(0)),.21)
  1565. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5+0.09*i, 0) * angles(math.rad(20-6*i), math.rad(0), math.rad(90+13*i)), 0.21)
  1566. LW.C0 = clerp(LW.C0, CFrame.new(-1.0-0.12*i, 0.5, -0.4+0.05*i) * angles(math.rad(20+13*i), math.rad(0), math.rad(20-13*i)), 0.21)
  1567. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(45+6*i), math.rad(0), math.rad(-22-4*i)), 0.21)
  1568. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(45+6*i), math.rad(0), math.rad(22+4*i)), 0.21)
  1569. end
  1570. homed = nil
  1571. attack = false
  1572. end))
  1573.  
  1574. end
  1575.  
  1576. end
  1577.  
  1578.  
  1579. end
  1580.  
  1581.  
  1582.  
  1583.  
  1584.  
  1585.  
  1586.  
  1587.  
  1588.  
  1589.  
  1590.  
  1591.  
  1592.  
  1593.  
  1594.  
  1595.  
  1596.  
  1597.  
  1598.  
  1599.  
  1600.  
  1601.  
  1602.  
  1603. mouse.KeyDown:connect(function(key)
  1604. wait(0.16)
  1605. if string.byte(key) == 32 and hitfloor == nil and attack == false and walljump == false and Humanoid.Jump == true then
  1606. walljumpp()
  1607. end
  1608. if string.byte(key) == 32 and hitfloor == nil and attack == false and walljump == false and Humanoid.Jump == true then
  1609. home()
  1610. end
  1611.  
  1612. if string.byte(key) == 32 and hitfloor == nil and attack == true and walljump == true then
  1613. walljump = false
  1614. end
  1615. end)
  1616.  
  1617.  
  1618.  
  1619.  
  1620. mouse.KeyDown:connect(function(key)
  1621. if key == 'm' and attack == false then
  1622. changemusic()
  1623. end
  1624. end)
  1625.  
  1626.  
  1627.  
  1628.  
  1629.  
  1630.  
  1631. mouse.KeyUp:connect(function(key)
  1632. wait(0.05)
  1633. if key == 'c' and sliding == true then
  1634. sliding = false
  1635. end
  1636. end)
  1637. local look = 0
  1638.  
  1639.  
  1640.  
  1641. while true do
  1642. swait()
  1643. sine = sine + change
  1644. --speed = speed + music.PlaybackLoudness/90
  1645. local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude
  1646. local velderp=RootPart.Velocity.y
  1647. hitfloor,posfloor=rayCast(RootPart.Position,(CFrame.new(RootPart.Position,RootPart.Position - Vector3.new(0,1,0))).lookVector,4,Character)
  1648.  
  1649. local TiltVelocity = CFrame.new(RootPart.CFrame:vectorToObjectSpace(RootPart.Velocity))
  1650.  
  1651. local rlegray = Ray.new(RightLeg.Position+Vector3.new(0,0.54,0),Vector3.new(0, -1.75, 0))
  1652. local rlegpart, rlegendPoint = workspace:FindPartOnRay(rlegray, Character)
  1653.  
  1654. local llegray = Ray.new(LeftLeg.Position+Vector3.new(0,0.54,0),Vector3.new(0, -1.75, 0))
  1655. local llegpart, llegendPoint = workspace:FindPartOnRay(llegray, Character)
  1656.  
  1657. local waterthing = Ray.new(RootPart.CFrame.p,Vector3.new(0,-1,0))
  1658. local start, position = workspace:FindPartOnRay(waterthing, character)
  1659.  
  1660. if start ~= nil and start.Material == "Water" then
  1661.  
  1662. RootPart.Velocity = RootPart.Velocity + Vector3.new(0,6,0)
  1663.  
  1664. end
  1665.  
  1666. Head.Running.Pitch = 0.76 + Humanoid.WalkSpeed/124
  1667. if torvel<1 and Swing == 2 then
  1668. boost = false
  1669. elseif torvel>1 and Swing == 2 then
  1670. boost = true
  1671. freefall = 0
  1672. end
  1673. if hitfloor ~= nil and freefall < 150 then
  1674. freefall = 0
  1675. end
  1676. if freefall > 150 and hitfloor ~= nil then
  1677. land()
  1678. freefall = 0
  1679. end
  1680.  
  1681.  
  1682.  
  1683.  
  1684.  
  1685.  
  1686.  
  1687. if RootPart.Velocity.y > 1 and hitfloor==nil then
  1688. Anim="Jump"
  1689.  
  1690.  
  1691.  
  1692.  
  1693.  
  1694. if attack==false then
  1695. change = 1
  1696. look = 0
  1697. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0,0,0),0.15)
  1698. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(4), math.rad(0), math.rad(0)), 0.07)
  1699. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-10+2.05*math.cos(sine/5)),math.rad(0),math.rad(0)),0.07)
  1700. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(-20+2.05*math.cos(sine/5)), math.rad(-10), math.rad(50-2.05*math.cos(sine/5))), 0.07)
  1701. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-20+2.05*math.cos(sine/5)), math.rad(-10), math.rad(-50+2.05*math.cos(sine/5))), 0.07)
  1702. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1, -0.6) * CFrame.Angles(math.rad(-25+3.05*math.cos(sine/5)), math.rad(-3), math.rad(0)), 0.1)
  1703. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -.47, -0.7) * CFrame.Angles(math.rad(-12+3.05*math.cos(sine/5)), math.rad(0), math.rad(0)), 0.1)
  1704. end
  1705.  
  1706. elseif RootPart.Velocity.y < -1 and freefall <150 and hitfloor==nil then
  1707. Anim="Fall"
  1708. change = 1
  1709. freefall = freefall +0.77
  1710.  
  1711.  
  1712. if attack==false then
  1713. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0,0,0),0.15)
  1714. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0.2) * CFrame.Angles(math.rad(7+4*math.sin(sine/1.3)), math.rad(0), math.rad(0)),0.07)
  1715. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.65, 0) * angles(math.rad(0), math.rad(0), math.rad(140+12*math.cos(sine/1.3))), 0.07)
  1716. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.65, 0) * angles(math.rad(0), math.rad(0), math.rad(-140+12*math.cos(sine/1.3))), 0.07)
  1717. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(40+7*math.sin(sine/1.3)),math.rad(0),math.rad(0)),0.07)
  1718. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1+0.17*math.cos(sine/1.3), -0.13) * CFrame.Angles(math.rad(18+7*math.cos(sine/1.3)), math.rad(3), math.rad(0)), 0.1)
  1719. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -.37+0.17*math.cos(sine/1.3), -0.2) * CFrame.Angles(math.rad(32+7*math.cos(sine/1.3)), math.rad(0), math.rad(0)), 0.1)
  1720. end
  1721.  
  1722.  
  1723.  
  1724. elseif RootPart.Velocity.y < -1 and freefall > 150 and hitfloor==nil then
  1725. Anim="FreeFall"
  1726. change = 1
  1727.  
  1728.  
  1729. if attack==false then
  1730. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0,0,0),0.15)
  1731. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1, 0.2) * CFrame.Angles(math.rad(-90+3*math.sin(sine/1.3)), math.rad(0), math.rad(0)),0.07)
  1732. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(14+12*math.cos(sine/1.3)), math.rad(0), math.rad(110)), 0.07)
  1733. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(14+12*math.cos(sine/1.3)), math.rad(0), math.rad(-110)), 0.07)
  1734. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-12+7*math.sin(sine/1.3)),math.rad(0),math.rad(0)),0.07)
  1735. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1+0.17*math.cos(sine/1.3),0.2) * CFrame.Angles(math.rad(-12+4*math.cos(sine/1.3)), math.rad(3), math.rad(-46)), 0.1)
  1736. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1+0.17*math.cos(sine/1.3), 0.2) * CFrame.Angles(math.rad(-12+4*math.cos(sine/1.3)), math.rad(0), math.rad(46)), 0.1)
  1737. end
  1738.  
  1739. elseif torvel<1 and hitfloor~=nil then
  1740. Anim="Idle"
  1741. change = 1
  1742. if attack==false and equip == false then
  1743.  
  1744. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0,0,0),0.15)
  1745. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1-0.04*math.cos(sine/40), -0) * CFrame.Angles(math.rad(0-0.81*math.cos(sine/40)), math.rad(-40), math.rad(0)), 0.1)
  1746. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0+2.6*math.sin(sine/40)),math.rad(0),math.rad(40)),0.1)
  1747. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.55+0.04*math.sin(sine/40), 0-0.04*math.cos(sine/40)) * angles(math.rad(-2+1.3*math.cos(sine/40)), math.rad(0+4*math.sin(sine/40)), math.rad(6.3+2.2*math.cos(sine/40))),0.1)
  1748. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.55+0.04*math.sin(sine/40), 0-0.04*math.cos(sine/40)) * angles(math.rad(2+1.3*math.cos(sine/40)), math.rad(0-4*math.sin(sine/40)), math.rad(-6.3-2.2*math.cos(sine/40))),0.1)
  1749. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, llegendPoint.Y-LeftLeg.Position.Y+0.04*math.cos(sine/40), 0) * CFrame.Angles(math.rad(0+0.81*math.cos(sine/40)), math.rad(18+0.81*math.cos(sine/40)), math.rad(-2-0.81*math.cos(sine/40))),0.1)
  1750. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.57, rlegendPoint.Y-RightLeg.Position.Y+0.04*math.cos(sine/40), 0) * CFrame.Angles(math.rad(0+0.81*math.cos(sine/40)), math.rad(-2+0.81*math.cos(sine/40)), math.rad(3-0.81*math.cos(sine/40))),0.1)
  1751. end
  1752.  
  1753.  
  1754.  
  1755. elseif torvel>1.5 and torvel<70 and hitfloor~=nil then
  1756. Anim="Walk"
  1757. change = 0.84+ Character.Humanoid.WalkSpeed/132
  1758. look = 0
  1759. if attack==false and equip == false then
  1760. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0,0,0),0.02)
  1761. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1-0.52*math.cos(sine/2), -.8) * angles(math.rad(-26), math.rad(0), math.rad(0)+ RootPart.RotVelocity.Y / 26), .1)
  1762. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-11+20*math.sin(sine/2)),math.rad(0),math.rad(0+5*math.sin(sine/4)) + RootPart.RotVelocity.Y / 13),.1)
  1763. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0.1) * angles(math.rad(-60-7*math.sin(sine/4))+ RootPart.RotVelocity.Y / -34, math.rad(0), math.rad(15+2*math.sin(sine/4))- RootPart.RotVelocity.Y / 34),.15)
  1764. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0.1)*angles(math.rad(-60-7*math.sin(sine/4))+ RootPart.RotVelocity.Y / 34,math.rad(0),math.rad(-15+2*math.sin(sine/4))+ RootPart.RotVelocity.Y / -34),.15)
  1765. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1+0.28*math.cos(sine/4), 0-0.32*math.cos(sine/4)) * CFrame.Angles(math.rad(0+104*math.sin(sine/4)), math.rad(0)+ RootPart.RotVelocity.Y / 42, math.rad(0)+ RootPart.RotVelocity.Y / -54), 0.3)
  1766. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1-0.28*math.cos(sine/4),0+0.32*math.cos(sine/4)) * CFrame.Angles(math.rad(0-104*math.sin(sine/4)), math.rad(0)+ RootPart.RotVelocity.Y / 42, math.rad(0)- RootPart.RotVelocity.Y / 54), 0.3)
  1767. end
  1768.  
  1769.  
  1770. elseif torvel>=70 and torvel<200 and hitfloor~=nil then
  1771. Anim="Run"
  1772. change = 0.84+ Character.Humanoid.WalkSpeed/142
  1773. if attack==false and equip == false then
  1774. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0,0,0),0.02)
  1775. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1-0.52*math.cos(sine/1.5), -.8) * angles(math.rad(-37), math.rad(0), math.rad(0)+ RootPart.RotVelocity.Y / 26), .1)
  1776. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-11+25*math.sin(sine/1.5)),math.rad(0),math.rad(0+5*math.sin(sine/3)) + RootPart.RotVelocity.Y / 13),.1)
  1777. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0.3) * angles(math.rad(-72-8*math.sin(sine/1.5))+ RootPart.RotVelocity.Y / -34, math.rad(0), math.rad(1+0*math.cos(sine/3))- RootPart.RotVelocity.Y / 34),.25)
  1778. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0.3)*angles(math.rad(-72-8*math.sin(sine/1.5))+ RootPart.RotVelocity.Y / 34,math.rad(0),math.rad(-1+0*math.cos(sine/3))+ RootPart.RotVelocity.Y / -34),.25)
  1779. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1+0.32*math.cos(sine/3), 0-0.42*math.cos(sine/3)) * CFrame.Angles(math.rad(0+134*math.sin(sine/3)), math.rad(0)+ RootPart.RotVelocity.Y / 42, math.rad(0)+ RootPart.RotVelocity.Y / -54), 0.44)
  1780. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1-0.32*math.cos(sine/3),0+0.42*math.cos(sine/3)) * CFrame.Angles(math.rad(0-134*math.sin(sine/3)), math.rad(0)+ RootPart.RotVelocity.Y / 42, math.rad(0)- RootPart.RotVelocity.Y / 54), 0.44)
  1781. end
  1782.  
  1783. --[[
  1784. if attack==false then
  1785. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1-0.4*math.cos(sine/5.5)/2, 0 *math.sin(sine/6.6)/2) * CFrame.Angles(math.rad(0) + -math.sin(sine/5.5)/1.2, math.rad(0), 0), .8)
  1786. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1+0.4*math.cos(sine/5.5)/2,0 *-math.sin(sine/6.6)/2) * CFrame.Angles(math.rad(0) + math.sin(sine/5.5)/1.2, math.rad(0), 0), .8)
  1787. end
  1788. ]]
  1789. if attack==true and noleg == false then
  1790. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1-0.24*math.cos(sine/5), 0.+0.24*math.cos(sine/5)) * CFrame.Angles(math.rad(0-74*math.sin(sine/5)), math.rad(0), math.rad(0)), 0.3)
  1791. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1+0.24*math.cos(sine/5),0.-0.24*math.cos(sine/5)) * CFrame.Angles(math.rad(0+74*math.sin(sine/5)), math.rad(0), math.rad(0)), 0.3)
  1792. end
  1793.  
  1794.  
  1795.  
  1796. elseif torvel>=200 and hitfloor~=nil then
  1797. Anim="MachRun"
  1798. change = 0.84+ Character.Humanoid.WalkSpeed/182
  1799. if attack==false and equip == false then
  1800. Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0,0,0),0.02)
  1801. Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, -1-0.52*math.cos(sine/1), -3.8) * angles(math.rad(-44), math.rad(0), math.rad(0)+ RootPart.RotVelocity.Y / 26), .2)
  1802. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-11+25*math.sin(sine/1)),math.rad(0),math.rad(0+5*math.sin(sine/2)) + RootPart.RotVelocity.Y / 13),.2)
  1803. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0.5) * angles(math.rad(-78-12*math.sin(sine/1))+ RootPart.RotVelocity.Y / -34, math.rad(0), math.rad(-24+0*math.cos(sine/2))- RootPart.RotVelocity.Y / 34),.35)
  1804. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0.5)*angles(math.rad(-78-12*math.sin(sine/1))+ RootPart.RotVelocity.Y / 34,math.rad(0),math.rad(24+0*math.cos(sine/2))+ RootPart.RotVelocity.Y / -34),.35)
  1805. LeftLeg.Weld.C0 = clerp(LeftLeg.Weld.C0, CFrame.new(-0.5, -1+0.42*math.cos(sine/2), 0-0.62*math.cos(sine/2)) * CFrame.Angles(math.rad(0+134*math.sin(sine/2)), math.rad(0)+ RootPart.RotVelocity.Y / 42, math.rad(0)+ RootPart.RotVelocity.Y / -54), 0.52)
  1806. RightLeg.Weld.C0 = clerp(RightLeg.Weld.C0, CFrame.new(0.5, -1-0.42*math.cos(sine/2),0+0.62*math.cos(sine/2)) * CFrame.Angles(math.rad(0-134*math.sin(sine/2)), math.rad(0)+ RootPart.RotVelocity.Y / 42, math.rad(0)- RootPart.RotVelocity.Y / 54), 0.52)
  1807. end
  1808.  
  1809.  
  1810.  
  1811. end
  1812.  
  1813.  
  1814.  
  1815.  
  1816.  
  1817.  
  1818.  
  1819.  
  1820.  
  1821. if 0 < #Effects then
  1822. for e = 1, #Effects do
  1823. if Effects[e] ~= nil then
  1824. local Thing = Effects[e]
  1825. if Thing ~= nil then
  1826. local Part = Thing[1]
  1827. local Mode = Thing[2]
  1828. local Delay = Thing[3]
  1829. local IncX = Thing[4]
  1830. local IncY = Thing[5]
  1831. local IncZ = Thing[6]
  1832. if Thing[1].Transparency <= 1 then
  1833. if Thing[2] == "Block1" then
  1834. Thing[1].CFrame = Thing[1].CFrame * euler(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  1835. Mesh = Thing[1]:FindFirstChild("Mesh")
  1836. if not Mesh then
  1837. Mesh = Instance.new("BlockMesh")
  1838. end
  1839. Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6])
  1840. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1841. elseif Thing[2] == "Cylinder" then
  1842. Mesh = Thing[1]:FindFirstChild("Mesh")
  1843. if not Mesh then
  1844. Mesh = Instance.new("BlockMesh")
  1845. end
  1846. Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6])
  1847. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1848. elseif Thing[2] == "Blood" then
  1849. Mesh = Thing[1]:FindFirstChild("Mesh")
  1850. if not Mesh then
  1851. Mesh = Instance.new("BlockMesh")
  1852. end
  1853. Thing[1].CFrame = Thing[1].CFrame * cf(0, 0.5, 0)
  1854. Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6])
  1855. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1856. elseif Thing[2] == "Elec" then
  1857. Mesh = Thing[1]:FindFirstChild("Mesh")
  1858. if not Mesh then
  1859. Mesh = Instance.new("BlockMesh")
  1860. end
  1861. Mesh.Scale = Mesh.Scale + vt(Thing[7], Thing[8], Thing[9])
  1862. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1863. elseif Thing[2] == "Disappear" then
  1864. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1865. end
  1866. else
  1867. Part.Parent = nil
  1868. game:GetService("Debris"):AddItem(Part, 0)
  1869. table.remove(Effects, e)
  1870. end
  1871. end
  1872. end
  1873. end
  1874. end
  1875.  
  1876. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement