Advertisement
DarkScriptZEditors

Heartbeat

Dec 20th, 2018
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 52.31 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,game,owner = owner,game
  3. local RealPlayer = Player
  4. do
  5. print("FE Compatibility code by Mokiros")
  6. local rp = RealPlayer
  7. script.Parent = rp.Character
  8.  
  9. --RemoteEvent for communicating
  10. local Event = Instance.new("RemoteEvent")
  11. Event.Name = "UserInput_Event"
  12.  
  13. --Fake event to make stuff like Mouse.KeyDown work
  14. local function fakeEvent()
  15. local t = {_fakeEvent=true,Functions={},Connect=function(self,f)table.insert(self.Functions,f) end}
  16. t.connect = t.Connect
  17. return t
  18. end
  19.  
  20. --Creating fake input objects with fake variables
  21. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent(),Button2Up=fakeEvent(),Button2Down=fakeEvent()}
  22. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  23. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  24. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  25. end}
  26. --Merged 2 functions into one by checking amount of arguments
  27. CAS.UnbindAction = CAS.BindAction
  28.  
  29. --This function will trigger the events that have been :Connect()'ed
  30. local function te(self,ev,...)
  31. local t = m[ev]
  32. if t and t._fakeEvent then
  33. for _,f in pairs(t.Functions) do
  34. f(...)
  35. end
  36. end
  37. end
  38. m.TrigEvent = te
  39. UIS.TrigEvent = te
  40.  
  41. Event.OnServerEvent:Connect(function(plr,io)
  42. if plr~=rp then return end
  43. m.Target = io.Target
  44. m.Hit = io.Hit
  45. if not io.isMouse then
  46. local b = io.UserInputState == Enum.UserInputState.Begin
  47. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  48. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  49. end
  50. if io.UserInputType == Enum.UserInputType.MouseButton2 then
  51. return m:TrigEvent(b and "Button2Down" or "Button2Up")
  52. end
  53. for _,t in pairs(CAS.Actions) do
  54. for _,k in pairs(t.Keys) do
  55. if k==io.KeyCode then
  56. t.Function(t.Name,io.UserInputState,io)
  57. end
  58. end
  59. end
  60. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  61. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  62. end
  63. end)
  64. Event.Parent = NLS([==[
  65. local Player = game:GetService("Players").LocalPlayer
  66. local Event = script:WaitForChild("UserInput_Event")
  67. local Mouse = Player:GetMouse()
  68. local UIS = game:GetService("UserInputService")
  69. local input = function(io,a)
  70. if a then return end
  71. --Since InputObject is a client-side instance, we create and pass table instead
  72. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
  73. end
  74. UIS.InputBegan:Connect(input)
  75. UIS.InputEnded:Connect(input)
  76. local h,t
  77. --Give the server mouse data 30 times every second, but only if the values changed
  78. --If player is not moving their mouse, client won't fire events
  79. while wait(1/30) do
  80. if h~=Mouse.Hit or t~=Mouse.Target then
  81. h,t=Mouse.Hit,Mouse.Target
  82. Event:FireServer({isMouse=true,Target=t,Hit=h})
  83. end
  84. end]==],Player.Character)
  85.  
  86. ----Sandboxed game object that allows the usage of client-side methods and services
  87. --Real game object
  88. local _rg = game
  89.  
  90. --Metatable for fake service
  91. local fsmt = {
  92. __index = function(self,k)
  93. local s = rawget(self,"_RealService")
  94. if s then
  95. return typeof(s[k])=="function"
  96. and function(_,...)return s[k](s,...)end or s[k]
  97. end
  98. end,
  99. __newindex = function(self,k,v)
  100. local s = rawget(self,"_RealService")
  101. if s then s[k]=v end
  102. end
  103. }
  104. local function FakeService(t,RealService)
  105. t._RealService = typeof(RealService)=="string" and _rg:GetService(RealService) or RealService
  106. return setmetatable(t,fsmt)
  107. end
  108.  
  109. --Fake game object
  110. local g = {
  111. GetService = function(self,s)
  112. return rawget(self,s) or _rg:GetService(s)
  113. end,
  114. Players = FakeService({
  115. LocalPlayer = FakeService({GetMouse=function(self)return m end},Player)
  116. },"Players"),
  117. UserInputService = FakeService(UIS,"UserInputService"),
  118. ContextActionService = FakeService(CAS,"ContextActionService"),
  119. RunService = FakeService({
  120. _btrs = {},
  121. RenderStepped = _rg:GetService("RunService").Heartbeat,
  122. BindToRenderStep = function(self,name,_,fun)
  123. self._btrs[name] = self.Heartbeat:Connect(fun)
  124. end,
  125. UnbindFromRenderStep = function(self,name)
  126. self._btrs[name]:Disconnect()
  127. end,
  128. },"RunService")
  129. }
  130. rawset(g.Players,"localPlayer",g.Players.LocalPlayer)
  131. g.service = g.GetService
  132. FakeService(g,game)
  133. --Changing owner to fake player object to support owner:GetMouse()
  134. game,owner = g,g.Players.LocalPlayer
  135. end
  136. -- Created by Nebula_Zorua --
  137. -- Heartbeat --
  138. -- Bwah. --
  139. -- Discord: Nebula the Zorua#6969
  140. -- Youtube: https://www.youtube.com/channel/UCo9oU9dCw8jnuVLuy4_SATA
  141.  
  142.  
  143.  
  144. --// Shortcut Variables \\--
  145. local S = setmetatable({},{__index = function(s,i) return game:service(i) end})
  146. local CF = {N=CFrame.new,A=CFrame.Angles,fEA=CFrame.fromEulerAnglesXYZ}
  147. local C3 = {N=Color3.new,RGB=Color3.fromRGB,HSV=Color3.fromHSV,tHSV=Color3.toHSV}
  148. local V3 = {N=Vector3.new,FNI=Vector3.FromNormalId,A=Vector3.FromAxis}
  149. local M = {C=math.cos,R=math.rad,S=math.sin,P=math.pi,RNG=math.random,MRS=math.randomseed,H=math.huge,RRNG = function(min,max,div) return math.rad(math.random(min,max)/(div or 1)) end}
  150. local R3 = {N=Region3.new}
  151. local De = S.Debris
  152. local WS = workspace
  153. local Lght = S.Lighting
  154. local RepS = S.ReplicatedStorage
  155. local IN = Instance.new
  156. local Plrs = S.Players
  157.  
  158. --// Initializing \\--
  159. local Plr = Plrs.LocalPlayer
  160. local Char = Plr.Character
  161. local Hum = Char:FindFirstChildOfClass'Humanoid'
  162. local RArm = Char["Right Arm"]
  163. local LArm = Char["Left Arm"]
  164. local RLeg = Char["Right Leg"]
  165. local LLeg = Char["Left Leg"]
  166. local Root = Char:FindFirstChild'HumanoidRootPart'
  167. local Torso = Char.Torso
  168. local Head = Char.Head
  169. local NeutralAnims = true
  170. local Attack = false
  171. local Debounces = {Debounces={}}
  172. local Mouse = Plr:GetMouse()
  173. local Hit = {}
  174. local Sine = 0
  175. local Change = 1
  176.  
  177. local Hearts = {}
  178.  
  179. local Effects = IN("Folder",Char)
  180. Effects.Name = "Effects"
  181.  
  182.  
  183. --// Debounce System \\--
  184.  
  185.  
  186. function Debounces:New(name,cooldown)
  187. local aaaaa = {Usable=true,Cooldown=cooldown or 2,CoolingDown=false,LastUse=0}
  188. setmetatable(aaaaa,{__index = Debounces})
  189. Debounces.Debounces[name] = aaaaa
  190. return aaaaa
  191. end
  192.  
  193. function Debounces:Use(overrideUsable)
  194. assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use")
  195. if(self.Usable or overrideUsable)then
  196. self.Usable = false
  197. self.CoolingDown = true
  198. local LastUse = time()
  199. self.LastUse = LastUse
  200. delay(self.Cooldown or 2,function()
  201. if(self.LastUse == LastUse)then
  202. self.CoolingDown = false
  203. self.Usable = true
  204. end
  205. end)
  206. end
  207. end
  208.  
  209. function Debounces:Get(name)
  210. assert(typeof(name) == 'string',("bad argument #1 to 'get' (string expected, got %s)"):format(typeof(name) == nil and "no value" or typeof(name)))
  211. for i,v in next, Debounces.Debounces do
  212. if(i == name)then
  213. return v;
  214. end
  215. end
  216. end
  217.  
  218. function Debounces:GetProgressPercentage()
  219. assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use")
  220. if(self.CoolingDown and not self.Usable)then
  221. return math.max(
  222. math.floor(
  223. (
  224. (time()-self.LastUse)/self.Cooldown or 2
  225. )*100
  226. )
  227. )
  228. else
  229. return 100
  230. end
  231. end
  232.  
  233. --// Instance Creation Functions \\--
  234.  
  235. function Sound(parent,id,pitch,volume,looped,effect,autoPlay)
  236. local Sound = IN("Sound")
  237. Sound.SoundId = "rbxassetid://".. tostring(id or 0)
  238. Sound.Pitch = pitch or 1
  239. Sound.Volume = volume or 1
  240. Sound.Looped = looped or false
  241. if(autoPlay)then
  242. coroutine.wrap(function()
  243. repeat wait() until Sound.IsLoaded
  244. Sound.Playing = autoPlay or false
  245. end)()
  246. end
  247. if(not looped and effect)then
  248. Sound.Stopped:connect(function()
  249. Sound.Volume = 0
  250. Sound:destroy()
  251. end)
  252. elseif(effect)then
  253. warn("Sound can't be looped and a sound effect!")
  254. end
  255. Sound.Parent =parent or Torso
  256. return Sound
  257. end
  258. function Part(parent,color,material,size,cframe,anchored,cancollide)
  259. local part = IN("Part")
  260. part.Parent = parent or Char
  261. part[typeof(color) == 'BrickColor' and 'BrickColor' or 'Color'] = color or C3.N(.2,0,0)
  262. part.Material = material or Enum.Material.SmoothPlastic
  263. part.TopSurface,part.BottomSurface=10,10
  264. part.Size = size or V3.N(1,1,1)
  265. part.CFrame = cframe or CF.N(0,0,0)
  266. part.Anchored = (anchored or true)
  267. part.CanCollide = cancollide or false
  268. return part
  269. end
  270. function Mesh(parent,meshtype,meshid,textid,scale,offset)
  271. local part = IN("SpecialMesh")
  272. part.MeshId = meshid or ""
  273. part.TextureId = textid or ""
  274. part.Scale = scale or V3.N(1,1,1)
  275. part.Offset = offset or V3.N(0,0,0)
  276. part.MeshType = meshtype or Enum.MeshType.Sphere
  277. part.Parent = parent
  278. return part
  279. end
  280.  
  281. NewInstance = function(instance,parent,properties)
  282. local inst = Instance.new(instance)
  283. inst.Parent = parent
  284. if(properties)then
  285. for i,v in next, properties do
  286. pcall(function() inst[i] = v end)
  287. end
  288. end
  289. return inst;
  290. end
  291.  
  292. function Clone(instance,parent,properties)
  293. local inst = instance:Clone()
  294. inst.Parent = parent
  295. if(properties)then
  296. for i,v in next, properties do
  297. pcall(function() inst[i] = v end)
  298. end
  299. end
  300. return inst;
  301. end
  302.  
  303. function SoundPart(id,pitch,volume,looped,effect,autoPlay,cf)
  304. local soundPart = NewInstance("Part",Effects,{Transparency=1,CFrame=cf or Torso.CFrame,Anchored=true,CanCollide=false,Size=V3.N()})
  305. local Sound = IN("Sound")
  306. Sound.SoundId = "rbxassetid://".. tostring(id or 0)
  307. Sound.Pitch = pitch or 1
  308. Sound.Volume = volume or 1
  309. Sound.Looped = looped or false
  310. if(autoPlay)then
  311. coroutine.wrap(function()
  312. repeat wait() until Sound.IsLoaded
  313. Sound.Playing = autoPlay or false
  314. end)()
  315. end
  316. if(not looped and effect)then
  317. Sound.Stopped:connect(function()
  318. Sound.Volume = 0
  319. soundPart:destroy()
  320. end)
  321. elseif(effect)then
  322. warn("Sound can't be looped and a sound effect!")
  323. end
  324. Sound.Parent = soundPart
  325. return Sound
  326. end
  327.  
  328. function AOEKill(where,range)
  329. for _,v in next, getRegion(where,range,{Char}) do
  330. if(v.Parent and v.Parent:FindFirstChildOfClass'Humanoid')then
  331. Kill(v.Parent)
  332. end
  333. end
  334. end
  335. --// Extended ROBLOX tables \\--
  336. local Instance = setmetatable({ClearChildrenOfClass = function(where,class,recursive) local children = (recursive and where:GetDescendants() or where:GetChildren()) for _,v in next, children do if(v:IsA(class))then v:destroy();end;end;end},{__index = Instance})
  337. --// Require stuff \\--
  338. function CamShake(who,times,intense,origin)
  339. coroutine.wrap(function()
  340. if(script:FindFirstChild'CamShake')then
  341. local cam = script.CamShake:Clone()
  342. cam:WaitForChild'intensity'.Value = intense
  343. cam:WaitForChild'times'.Value = times
  344.  
  345. if(origin)then NewInstance((typeof(origin) == 'Instance' and "ObjectValue" or typeof(origin) == 'Vector3' and 'Vector3Value'),cam,{Name='origin',Value=origin}) end
  346. cam.Parent = who
  347. wait()
  348. cam.Disabled = false
  349. elseif(who == Plr or who == Char)then
  350. local intensity = intense
  351. local cam = workspace.CurrentCamera
  352. for i = 1, times do
  353. local camDistFromOrigin
  354. if(typeof(origin) == 'Instance' and origin:IsA'BasePart')then
  355. camDistFromOrigin = math.floor( (cam.CFrame.p-origin.Position).magnitude )/25
  356. elseif(typeof(origin) == 'Vector3')then
  357. camDistFromOrigin = math.floor( (cam.CFrame.p-origin).magnitude )/25
  358. end
  359. if(camDistFromOrigin)then
  360. intensity = math.min(intense, math.floor(intense/camDistFromOrigin))
  361. end
  362. cam.CFrame = cam.CFrame:lerp(cam.CFrame*CFrame.new(math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100)*CFrame.Angles(math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100)),.4)
  363. swait()
  364. end
  365. end
  366. end)()
  367. end
  368.  
  369. function CamShakeAll(times,intense,origin)
  370. for _,v in next, Plrs:players() do
  371. CamShake(v:FindFirstChildOfClass'PlayerGui' or v:FindFirstChildOfClass'Backpack' or v.Character,times,intense,origin)
  372. end
  373. end
  374.  
  375. function ServerScript(code)
  376. if(script:FindFirstChild'Loadstring')then
  377. local load = script.Loadstring:Clone()
  378. load:WaitForChild'Sauce'.Value = code
  379. load.Disabled = false
  380. load.Parent = workspace
  381. elseif(NS and typeof(NS) == 'function')then
  382. NS(code,workspace)
  383. else
  384. warn("no serverscripts lol")
  385. end
  386. end
  387.  
  388. function RunLocal(where,code)
  389. ServerScript([[
  390. wait()
  391. script.Parent=nil
  392. if(not _G.Http)then _G.Http = game:service'HttpService' end
  393.  
  394. local Http = _G.Http or game:service'HttpService'
  395.  
  396. local source = ]].."[["..code.."]]"..[[
  397. local link = "https://api.vorth.xyz/R_API/R.UPLOAD/NEW_LOCAL.php"
  398. local asd = Http:PostAsync(link,source)
  399. repeat wait() until asd and Http:JSONDecode(asd) and Http:JSONDecode(asd).Result and Http:JSONDecode(asd).Result.Require_ID
  400. local ID = Http:JSONDecode(asd).Result.Require_ID
  401. local vs = require(ID).VORTH_SCRIPT
  402. vs.Parent = game.]]..where:GetFullName()
  403. )
  404. end
  405.  
  406. --// Customization \\--
  407.  
  408. local Frame_Speed = 60 -- The frame speed for swait. 1 is automatically divided by this
  409. local Remove_Hats = false
  410. local Remove_Clothing = false
  411. local PlayerSize = 1
  412. local DamageColor = BrickColor.new'Maroon'
  413. local MusicID = 1306847940
  414. local God = true
  415. local Muted = false
  416.  
  417. local WalkSpeed = 8
  418.  
  419. --// Weapon and GUI creation, and Character Customization \\--
  420.  
  421. local BloodRainPart = NewInstance("Part",Char,{Transparency=1,Anchored=true,CanCollide=false,CFrame=CF.N(0,240,0),Size=V3.N(750,.05,750)})
  422. local Particles = NewInstance("ParticleEmitter",BloodRainPart,{
  423. Color=ColorSequence.new(C3.RGB(161,0,0)),
  424. LightEmission=0,
  425. LightInfluence=0,
  426. Size=NumberSequence.new(2),
  427. Texture="rbxassetid://419625073",
  428. Transparency=NumberSequence.new(0),
  429. Acceleration=V3.N(0,-workspace.Gravity,0),
  430. LockedToPart=true,
  431. Lifetime=NumberRange.new(10,15),
  432. Rate=math.huge,
  433. SpreadAngle=Vector2.new(1,1)
  434. })
  435.  
  436. local Particles2 = Particles:Clone()
  437. Particles2.Parent= BloodRainPart
  438.  
  439.  
  440. local Skybox = NewInstance("Part",Effects,{Anchored=true,CanCollide=false,Size=V3.N(.05,.05,.05)})
  441. local SkyMesh = NewInstance("SpecialMesh",Skybox,{
  442. Scale=V3.N(-3000,-1000,-3000),
  443. VertexColor=V3.N(1,0,0),
  444. MeshId="http://www.roblox.com/asset/?id=1527559",
  445. TextureId="http://www.roblox.com/asset/?id=1529460"
  446. })
  447.  
  448. --local h = workspace.Heart:Clone() local vis = Instance.new("Model",workspace) vis.Name = 'hearts' local countX = 0; for i = 1, 360,30 do local hrt = h:Clone(); hrt.Parent = vis; hrt.CFrame = CFrame.Angles(0,math.rad(i),0)*CFrame.new(0,0,-853) end
  449.  
  450. for _, c in next, Char:GetDescendants() do
  451. if c and c.Parent then
  452. if c.Name == "Handle" and c.Parent.ClassName == "Accessory" then
  453. local ACCESSORY = c.Parent
  454. c.Parent = Char
  455. if c then
  456. if c:FindFirstChild("HatAttachment") or c:FindFirstChild("FaceFrontAttachment") or c:FindFirstChild("HairAttachment") then
  457. local weldd = IN("Weld")
  458. weldd.Part0 = Head
  459. weldd.Part1 = c
  460. weldd.C0 = CF.N()
  461. weldd.C1 = c.CFrame:inverse() * Head.CFrame
  462. weldd.Parent = Head
  463. else
  464. local weldd = IN("Weld")
  465. weldd.Part0 = Torso
  466. weldd.Part1 = c
  467. weldd.C0 = CF.N()
  468. weldd.C1 = c.CFrame:inverse() * Torso.CFrame
  469. weldd.Parent = Torso
  470. end
  471. end
  472. ACCESSORY:remove()
  473. elseif c.Parent.ClassName ~= "Accessory" and c.ClassName == "Part" and c.Name ~= "Eye" and c.Parent ~= Effects and c.Parent.Parent ~= Effects then
  474. c.Material = "Glass"
  475. c.Color = C3.N(.2,0,0)
  476. if c:FindFirstChildOfClass("SpecialMesh") and c ~= Skybox then
  477. c:FindFirstChildOfClass("SpecialMesh").TextureId = ""
  478. end
  479. if c == Head then
  480. if c:FindFirstChild("face") and Plr.Name ~= 'CKbackup' then
  481. c.face:remove()
  482. end
  483. end
  484. elseif c.ClassName == "Part" and c.Name == "Eye" then
  485. c.Color = C3.N(1,0,0)
  486. c.Material = "Glass"
  487. elseif c.Name == "Body Colors" then
  488. c:remove()
  489. elseif (c.ClassName == "Shirt" or c.ClassName == "Pants") then
  490. c:remove()
  491. end
  492. end
  493. end
  494.  
  495. for i = 1, 360,30 do
  496. --local hrt = h:Clone(); hrt.Parent = vis; hrt.CFrame =
  497. local hrt = NewInstance("Part",Effects,{Name='Heart',Anchored=true,CanCollide=false,Color=C3.N(1,0,0),Size=V3.N(345,307,16),Locked=true,Archivable=false,CFrame=CF.A(0,M.R(i),M.R(180))*CF.N(0,0,-923)})
  498. local hrtMesh = NewInstance("SpecialMesh",hrt,{MeshId="rbxassetid://105992239",Offset=V3.N(0,0,-10),Scale=V3.N(-750,-750,-100)})
  499. table.insert(Hearts,{hrt,hrtMesh,i})
  500. end
  501.  
  502. if(Remove_Hats)then Instance.ClearChildrenOfClass(Char,"Accessory",true) end
  503. if(Remove_Clothing)then Instance.ClearChildrenOfClass(Char,"Clothing",true) Instance.ClearChildrenOfClass(Char,"ShirtGraphic",true) end
  504.  
  505. if(PlayerSize ~= 1)then
  506. for _,v in next, Char:GetDescendants() do
  507. if(v:IsA'BasePart')then
  508. v.Size = v.Size * PlayerSize
  509. end
  510. end
  511. end
  512.  
  513.  
  514. local Music = Sound(Char,MusicID,1,3,true,false,true)
  515. Music.Name = 'Music'
  516.  
  517. --// Stop animations \\--
  518. for _,v in next, Hum:GetPlayingAnimationTracks() do
  519. v:Stop();
  520. end
  521.  
  522. pcall(game.Destroy,Char:FindFirstChild'Animate')
  523. pcall(game.Destroy,Hum:FindFirstChild'Animator')
  524.  
  525. --// Joints \\--
  526.  
  527. local LS = NewInstance('Motor',Char,{Part0=Torso,Part1=LArm,C0 = CF.N(-1.5 * PlayerSize,0.5 * PlayerSize,0),C1 = CF.N(0,.5 * PlayerSize,0)})
  528. local RS = NewInstance('Motor',Char,{Part0=Torso,Part1=RArm,C0 = CF.N(1.5 * PlayerSize,0.5 * PlayerSize,0),C1 = CF.N(0,.5 * PlayerSize,0)})
  529. local NK = NewInstance('Motor',Char,{Part0=Torso,Part1=Head,C0 = CF.N(0,1.5 * PlayerSize,0)})
  530. local LH = NewInstance('Motor',Char,{Part0=Torso,Part1=LLeg,C0 = CF.N(-.5 * PlayerSize,-1 * PlayerSize,0),C1 = CF.N(0,1 * PlayerSize,0)})
  531. local RH = NewInstance('Motor',Char,{Part0=Torso,Part1=RLeg,C0 = CF.N(.5 * PlayerSize,-1 * PlayerSize,0),C1 = CF.N(0,1 * PlayerSize,0)})
  532. local RJ = NewInstance('Motor',Char,{Part0=Root,Part1=Torso})
  533.  
  534. local LSC0 = LS.C0
  535. local RSC0 = RS.C0
  536. local NKC0 = NK.C0
  537. local LHC0 = LH.C0
  538. local RHC0 = RH.C0
  539. local RJC0 = RJ.C0
  540.  
  541. --// Artificial HB \\--
  542.  
  543. local ArtificialHB = IN("BindableEvent", script)
  544. ArtificialHB.Name = "Heartbeat"
  545.  
  546. script:WaitForChild("Heartbeat")
  547.  
  548. local tf = 0
  549. local allowframeloss = false
  550. local tossremainder = false
  551. local lastframe = tick()
  552. local frame = 1/Frame_Speed
  553. ArtificialHB:Fire()
  554.  
  555. game:GetService("RunService").Heartbeat:connect(function(s, p)
  556. tf = tf + s
  557. if tf >= frame then
  558. if allowframeloss then
  559. script.Heartbeat:Fire()
  560. lastframe = tick()
  561. else
  562. for i = 1, math.floor(tf / frame) do
  563. ArtificialHB:Fire()
  564. end
  565. lastframe = tick()
  566. end
  567. if tossremainder then
  568. tf = 0
  569. else
  570. tf = tf - frame * math.floor(tf / frame)
  571. end
  572. end
  573. end)
  574.  
  575. function swait(num)
  576. if num == 0 or num == nil then
  577. ArtificialHB.Event:wait()
  578. else
  579. for i = 0, num do
  580. ArtificialHB.Event:wait()
  581. end
  582. end
  583. end
  584.  
  585.  
  586. --// Effect Function(s) \\--
  587.  
  588. function Bezier(startpos, pos2, pos3, endpos, t)
  589. local A = startpos:lerp(pos2, t)
  590. local B = pos2:lerp(pos3, t)
  591. local C = pos3:lerp(endpos, t)
  592. local lerp1 = A:lerp(B, t)
  593. local lerp2 = B:lerp(C, t)
  594. local cubic = lerp1:lerp(lerp2, t)
  595. return cubic
  596. end
  597.  
  598. function SphereFX(duration,color,scale,pos,endScale,increment)
  599. return Effect{
  600. Effect='ResizeAndFade',
  601. Color=color,
  602. Size=scale,
  603. Mesh={MeshType=Enum.MeshType.Sphere},
  604. CFrame=pos,
  605. FXSettings={
  606. EndSize=endScale,
  607. EndIsIncrement=increment
  608. }
  609. }
  610. end
  611.  
  612. function BlastFX(duration,color,scale,pos,endScale,increment)
  613. return Effect{
  614. Effect='ResizeAndFade',
  615. Color=color,
  616. Size=scale,
  617. Mesh={MeshType=Enum.MeshType.FileMesh,MeshId='rbxassetid://20329976'},
  618. CFrame=pos,
  619. FXSettings={
  620. EndSize=endScale,
  621. EndIsIncrement=increment
  622. }
  623. }
  624. end
  625.  
  626. function BlockFX(duration,color,scale,pos,endScale,increment)
  627. return Effect{
  628. Effect='ResizeAndFade',
  629. Color=color,
  630. Size=scale,
  631. CFrame=pos,
  632. FXSettings={
  633. EndSize=endScale,
  634. EndIsIncrement=increment
  635. }
  636. }
  637. end
  638.  
  639. function Zap(data)
  640. local sCF,eCF = data.StartCFrame,data.EndCFrame
  641. assert(sCF,"You need a start CFrame!")
  642. assert(eCF,"You need an end CFrame!")
  643. local parts = data.PartCount or 15
  644. local zapRot = data.ZapRotation or {-5,5}
  645. local startThick = data.StartSize or 3;
  646. local endThick = data.EndSize or startThick/2;
  647. local color = data.Color or BrickColor.new'Electric blue'
  648. local delay = data.Delay or 35
  649. local delayInc = data.DelayInc or 0
  650. local lastLightning;
  651. local MagZ = (sCF.p - eCF.p).magnitude
  652. local thick = startThick
  653. local inc = (startThick/parts)-(endThick/parts)
  654.  
  655. for i = 1, parts do
  656. local pos = sCF.p
  657. if(lastLightning)then
  658. pos = lastLightning.CFrame*CF.N(0,0,MagZ/parts/2).p
  659. end
  660. delay = delay + delayInc
  661. local zapPart = Part(Effects,color,Enum.Material.Neon,V3.N(thick,thick,MagZ/parts),CF.N(pos),true,false)
  662. local posie = CF.N(pos,eCF.p)*CF.N(0,0,MagZ/parts).p+V3.N(M.RNG(unpack(zapRot)),M.RNG(unpack(zapRot)),M.RNG(unpack(zapRot)))
  663. if(parts == i)then
  664. local MagZ = (pos-eCF.p).magnitude
  665. zapPart.Size = V3.N(endThick,endThick,MagZ)
  666. zapPart.CFrame = CF.N(pos, eCF.p)*CF.N(0,0,-MagZ/2)
  667. Effect{Effect='ResizeAndFade',Size=V3.N(thick,thick,thick),CFrame=eCF*CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180)),Color=color,Frames=delay*2,FXSettings={EndSize=V3.N(thick*8,thick*8,thick*8)}}
  668. else
  669. zapPart.CFrame = CF.N(pos,posie)*CF.N(0,0,MagZ/parts/2)
  670. end
  671.  
  672. lastLightning = zapPart
  673. Effect{Effect='Fade',Manual=zapPart,Frames=delay}
  674.  
  675. thick=thick-inc
  676.  
  677. end
  678. end
  679.  
  680. function Zap2(data)
  681. local Color = data.Color or BrickColor.new'Electric blue'
  682. local StartPos = data.Start or Torso.Position
  683. local EndPos = data.End or Mouse.Hit.p
  684. local SegLength = data.SegL or 2
  685. local Thicc = data.Thickness or 0.5
  686. local Fades = data.Fade or 45
  687. local Parent = data.Parent or Effects
  688. local MaxD = data.MaxDist or 200
  689. local Branch = data.Branches or false
  690. local Material = data.Material or Enum.Material.Neon
  691. local Raycasts = data.Raycasts or false
  692. local Offset = data.Offset or {0,360}
  693. local AddMesh = (data.Mesh == nil and true or data.Mesh)
  694. if((StartPos-EndPos).magnitude > MaxD)then
  695. EndPos = CF.N(StartPos,EndPos)*CF.N(0,0,-MaxD).p
  696. end
  697. local hit,pos,norm,dist=nil,EndPos,nil,(StartPos-EndPos).magnitude
  698. if(Raycasts)then
  699. hit,pos,norm,dist = CastRay(StartPos,EndPos,MaxD)
  700. end
  701. local segments = dist/SegLength
  702. local model = IN("Model",Parent)
  703. model.Name = 'Lightning'
  704. local Last;
  705. for i = 1, segments do
  706. local size = (segments-i)/25
  707. local prt = Part(model,Color,Material,V3.N(Thicc+size,SegLength,Thicc+size),CF.N(),true,false)
  708. if(AddMesh)then IN("CylinderMesh",prt) end
  709. if(Last and math.floor(segments) == i)then
  710. local MagZ = (Last.CFrame*CF.N(0,-SegLength/2,0).p-EndPos).magnitude
  711. prt.Size = V3.N(Thicc+size,MagZ,Thicc+size)
  712. prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,EndPos)*CF.A(M.R(90),0,0)*CF.N(0,-MagZ/2,0)
  713. elseif(not Last)then
  714. prt.CFrame = CF.N(StartPos,pos)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  715. else
  716. prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,CF.N(pos)*CF.A(M.R(M.RNG(0,360)),M.R(M.RNG(0,360)),M.R(M.RNG(0,360)))*CF.N(0,0,SegLength/3+(segments-i)).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  717. end
  718. Last = prt
  719. if(Branch)then
  720. local choice = M.RNG(1,7+((segments-i)*2))
  721. if(choice == 1)then
  722. local LastB;
  723. for i2 = 1,M.RNG(2,5) do
  724. local size2 = ((segments-i)/35)/i2
  725. local prt = Part(model,Color,Material,V3.N(Thicc+size2,SegLength,Thicc+size2),CF.N(),true,false)
  726. if(AddMesh)then IN("CylinderMesh",prt) end
  727. if(not LastB)then
  728. prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,Last.CFrame*CF.N(0,-SegLength/2,0)*CF.A(0,0,M.RRNG(0,360))*CF.N(0,Thicc*7,0)*CF.N(0,0,-1).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  729. else
  730. prt.CFrame = CF.N(LastB.CFrame*CF.N(0,-SegLength/2,0).p,LastB.CFrame*CF.N(0,-SegLength/2,0)*CF.A(0,0,M.RRNG(0,360))*CF.N(0,Thicc*7,0)*CF.N(0,0,-1).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  731. end
  732. LastB = prt
  733. end
  734. end
  735. end
  736. end
  737. if(Fades > 0)then
  738. coroutine.wrap(function()
  739. for i = 1, Fades do
  740. for _,v in next, model:children() do
  741. if(v:IsA'BasePart')then
  742. v.Transparency = (i/Fades)
  743. end
  744. end
  745. swait()
  746. end
  747. model:destroy()
  748. end)()
  749. else
  750. S.Debris:AddItem(model,.01)
  751. end
  752. return {End=(Last and Last.CFrame*CF.N(0,-Last.Size.Y/2,0).p),Last=Last,Model=model}
  753. end
  754.  
  755. function Tween(obj,props,time,easing,direction,repeats,backwards)
  756. local info = TweenInfo.new(time or .5, easing or Enum.EasingStyle.Quad, direction or Enum.EasingDirection.Out, repeats or 0, backwards or false)
  757. local tween = S.TweenService:Create(obj, info, props)
  758.  
  759. tween:Play()
  760. end
  761.  
  762. function Effect(data)
  763. local FX = data.Effect or 'ResizeAndFade'
  764. local Parent = data.Parent or Effects
  765. local Color = data.Color or C3.N(.2,0,0)
  766. local Size = data.Size or V3.N(1,1,1)
  767. local MoveDir = data.MoveDirection or nil
  768. local MeshData = data.Mesh or nil
  769. local SndData = data.Sound or nil
  770. local Frames = data.Frames or 45
  771. local Manual = data.Manual or nil
  772. local Material = data.Material or nil
  773. local CFra = data.CFrame or Torso.CFrame
  774. local Settings = data.FXSettings or {}
  775. local Shape = data.Shape or Enum.PartType.Block
  776. local Snd,Prt,Msh;
  777. coroutine.wrap(function()
  778. if(Manual and typeof(Manual) == 'Instance' and Manual:IsA'BasePart')then
  779. Prt = Manual
  780. else
  781. Prt = Part(Parent,Color,Material,Size,CFra,true,false)
  782. Prt.Shape = Shape
  783. end
  784. if(typeof(MeshData) == 'table')then
  785. Msh = Mesh(Prt,MeshData.MeshType,MeshData.MeshId,MeshData.TextureId,MeshData.Scale,MeshData.Offset)
  786. elseif(typeof(MeshData) == 'Instance')then
  787. Msh = MeshData:Clone()
  788. Msh.Parent = Prt
  789. elseif(Shape == Enum.PartType.Block)then
  790. Msh = Mesh(Prt,Enum.MeshType.Brick)
  791. end
  792. if(typeof(SndData) == 'table' or typeof(SndData) == 'Instance')then
  793. Snd = Sound(Prt,SndData.SoundId,SndData.Pitch,SndData.Volume,false,false,true)
  794. end
  795. if(Snd)then
  796. repeat swait() until Snd.Playing and Snd.IsLoaded and Snd.TimeLength > 0
  797. Frames = Snd.TimeLength * Frame_Speed/Snd.Pitch
  798. end
  799. Size = (Msh and Msh.Scale or Size)
  800. local grow = Size-(Settings.EndSize or (Msh and Msh.Scale or Size)/2)
  801.  
  802. local MoveSpeed = nil;
  803. if(MoveDir)then
  804. MoveSpeed = (CFra.p - MoveDir).magnitude/Frames
  805. end
  806. if(FX ~= 'Arc')then
  807. for Frame = 1, Frames do
  808. if(FX == "Fade")then
  809. Prt.Transparency = (Frame/Frames)
  810. elseif(FX == "Resize")then
  811. if(not Settings.EndSize)then
  812. Settings.EndSize = V3.N(0,0,0)
  813. end
  814. if(Settings.EndIsIncrement)then
  815. if(Msh)then
  816. Msh.Scale = Msh.Scale + Settings.EndSize
  817. else
  818. Prt.Size = Prt.Size + Settings.EndSize
  819. end
  820. else
  821. if(Msh)then
  822. Msh.Scale = Msh.Scale - grow/Frames
  823. else
  824. Prt.Size = Prt.Size - grow/Frames
  825. end
  826. end
  827. elseif(FX == "ResizeAndFade")then
  828. if(not Settings.EndSize)then
  829. Settings.EndSize = V3.N(0,0,0)
  830. end
  831. if(Settings.EndIsIncrement)then
  832. if(Msh)then
  833. Msh.Scale = Msh.Scale + Settings.EndSize
  834. else
  835. Prt.Size = Prt.Size + Settings.EndSize
  836. end
  837. else
  838. if(Msh)then
  839. Msh.Scale = Msh.Scale - grow/Frames
  840. else
  841. Prt.Size = Prt.Size - grow/Frames
  842. end
  843. end
  844. Prt.Transparency = (Frame/Frames)
  845. end
  846. if(Settings.RandomizeCFrame)then
  847. Prt.CFrame = Prt.CFrame * CF.A(M.RRNG(-360,360),M.RRNG(-360,360),M.RRNG(-360,360))
  848. end
  849. if(MoveDir and MoveSpeed)then
  850. local Orientation = Prt.Orientation
  851. Prt.CFrame = CF.N(Prt.Position,MoveDir)*CF.N(0,0,-MoveSpeed)
  852. Prt.Orientation = Orientation
  853. end
  854. swait()
  855. end
  856. Prt:destroy()
  857. else
  858. local start,third,fourth,endP = Settings.Start,Settings.Third,Settings.Fourth,Settings.End
  859. if(not Settings.End and Settings.Home)then endP = Settings.Home.CFrame end
  860. if(start and endP)then
  861. local quarter = third or start:lerp(endP, 0.25) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
  862. local threequarter = fourth or start:lerp(endP, 0.75) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
  863. for Frame = 0, 1, (Settings.Speed or 0.01) do
  864. if(Settings.Home)then
  865. endP = Settings.Home.CFrame
  866. end
  867. Prt.CFrame = Bezier(start, quarter, threequarter, endP, Frame)
  868. end
  869. if(Settings.RemoveOnGoal)then
  870. Prt:destroy()
  871. end
  872. else
  873. Prt:destroy()
  874. assert(start,"You need a start position!")
  875. assert(endP,"You need a start position!")
  876. end
  877. end
  878. end)()
  879. return Prt,Msh,Snd
  880. end
  881. function SoulSteal(whom)
  882. local torso = (whom:FindFirstChild'Head' or whom:FindFirstChild'Torso' or whom:FindFirstChild'UpperTorso' or whom:FindFirstChild'LowerTorso' or whom:FindFirstChild'HumanoidRootPart')
  883. print(torso)
  884. if(torso and torso:IsA'BasePart')then
  885. local Model = Instance.new("Model",Effects)
  886. Model.Name = whom.Name.."'s Soul"
  887. whom:BreakJoints()
  888. local Soul = Part(Model,BrickColor.new'Really red','Glass',V3.N(.5,.5,.5),torso.CFrame,true,false)
  889. Soul.Name = 'Head'
  890. NewInstance("Humanoid",Model,{Health=0,MaxHealth=0})
  891. Effect{
  892. Effect="Arc",
  893. Manual = Soul,
  894. FXSettings={
  895. Start=torso.CFrame,
  896. Home = Torso,
  897. RemoveOnGoal = true,
  898. }
  899. }
  900. local lastPoint = Soul.CFrame.p
  901.  
  902. for i = 0, 1, 0.01 do
  903. local point = CFrame.new(lastPoint, Soul.Position) * CFrame.Angles(-math.pi/2, 0, 0)
  904. local mag = (lastPoint - Soul.Position).magnitude
  905. Effect{
  906. Effect = "Fade",
  907. CFrame = point * CF.N(0, mag/2, 0),
  908. Size = V3.N(.5,mag+.5,.5),
  909. Color = Soul.BrickColor
  910. }
  911. lastPoint = Soul.CFrame.p
  912. swait()
  913. end
  914. for i = 1, 5 do
  915. Effect{
  916. Effect="Fade",
  917. Color = BrickColor.new'Really red',
  918. MoveDirection = (Torso.CFrame*CFrame.new(M.RNG(-40,40),M.RNG(-40,40),M.RNG(-40,40))).p
  919. }
  920. end
  921. end
  922. end
  923.  
  924. --// Other Functions \\ --
  925.  
  926. function CastRay(startPos,endPos,range,ignoreList)
  927. local ray = Ray.new(startPos,(endPos-startPos).unit*range)
  928. local part,pos,norm = workspace:FindPartOnRayWithIgnoreList(ray,ignoreList or {Char},false,true)
  929. return part,pos,norm,(pos and (startPos-pos).magnitude)
  930. end
  931.  
  932. function getRegion(point,range,ignore)
  933. return workspace:FindPartsInRegion3WithIgnoreList(R3.N(point-V3.N(1,1,1)*range/2,point+V3.N(1,1,1)*range/2),ignore,100)
  934. end
  935.  
  936. function clerp(startCF,endCF,alpha)
  937. return startCF:lerp(endCF, alpha)
  938. end
  939.  
  940. function GetTorso(char)
  941. return char:FindFirstChild'Torso' or char:FindFirstChild'UpperTorso' or char:FindFirstChild'LowerTorso' or char:FindFirstChild'HumanoidRootPart'
  942. end
  943.  
  944. function ShowDamage(Pos, Text, Time, Color)
  945. coroutine.wrap(function()
  946. local Rate = (1 / Frame_Speed)
  947. local Pos = (Pos or Vector3.new(0, 0, 0))
  948. local Text = (Text or "")
  949. local Time = (Time or 2)
  950. local Color = (Color or Color3.new(1, 0, 1))
  951. local EffectPart = NewInstance("Part",Effects,{
  952. Material=Enum.Material.SmoothPlastic,
  953. Reflectance = 0,
  954. Transparency = 1,
  955. BrickColor = BrickColor.new(Color),
  956. Name = "Effect",
  957. Size = Vector3.new(0,0,0),
  958. Anchored = true,
  959. CFrame = CF.N(Pos)
  960. })
  961. local BillboardGui = NewInstance("BillboardGui",EffectPart,{
  962. Size = UDim2.new(1.25, 0, 1.25, 0),
  963. Adornee = EffectPart,
  964. })
  965. local TextLabel = NewInstance("TextLabel",BillboardGui,{
  966. BackgroundTransparency = 1,
  967. Size = UDim2.new(1, 0, 1, 0),
  968. Text = Text,
  969. Font = "Bodoni",
  970. TextColor3 = Color,
  971. TextStrokeColor3 = Color3.new(0,0,0),
  972. TextStrokeTransparency=0,
  973. TextScaled = true,
  974. })
  975. S.Debris:AddItem(EffectPart, (Time))
  976. EffectPart.Parent = workspace
  977. delay(0, function()
  978. Tween(EffectPart,{CFrame=CF.N(Pos)*CF.N(0,3,0)},Time,Enum.EasingStyle.Elastic,Enum.EasingDirection.Out)
  979. local Frames = (Time / Rate)
  980. for Frame = 1, Frames do
  981. swait()
  982. local Percent = (Frame / Frames)
  983. TextLabel.TextTransparency = Percent
  984. TextLabel.TextStrokeTransparency = Percent
  985. end
  986. if EffectPart and EffectPart.Parent then
  987. EffectPart:Destroy()
  988. end
  989. end) end)()
  990. end
  991.  
  992.  
  993. function DealDamage(who,minDam,maxDam,Knock,Type,critChance,critMult)
  994. if(who)then
  995. local hum = who:FindFirstChildOfClass'Humanoid'
  996. local Damage = M.RNG(minDam,maxDam)
  997. local canHit = true
  998. if(hum)then
  999. for _, p in pairs(Hit) do
  1000. if p[1] == hum then
  1001. if(time() - p[2] < 0.1) then
  1002. canHit = false
  1003. else
  1004. Hit[_] = nil
  1005. end
  1006. end
  1007. end
  1008. if(canHit)then
  1009. table.insert(Hit,{hum,time()})
  1010. if(hum.Health >= math.huge)then
  1011. who:BreakJoints()
  1012. if(who:FindFirstChild'Head' and hum.Health > 0)then
  1013. ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "INSTANT", 1.5, C3.N(1,0,0))
  1014. end
  1015. else
  1016. local player = S.Players:GetPlayerFromCharacter(who)
  1017. if(Type == "Fire")then
  1018. --idk..
  1019. else
  1020. local c = Instance.new("ObjectValue",hum)
  1021. c.Name = "creator"
  1022. c.Value = Plr
  1023. game:service'Debris':AddItem(c,0.35)
  1024. if(M.RNG(1,100) <= (critChance or 0) and critMult > 1)then
  1025. if(who:FindFirstChild'Head' and hum.Health > 0)then
  1026. ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "[CRIT] "..Damage*(critMult or 2), 1.5, BrickColor.new'New Yeller'.Color)
  1027. end
  1028. hum.Health = hum.Health - Damage*(critMult or 2)
  1029. else
  1030. if(who:FindFirstChild'Head' and hum.Health > 0)then
  1031. ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), Damage, 1.5, DamageColor.Color)
  1032. end
  1033. hum.Health = hum.Health - Damage
  1034. end
  1035. if(Type == 'Knockback' and GetTorso(who))then
  1036. local angle = GetTorso(who).Position - Root.Position + Vector3.new(0, 0, 0).unit
  1037. local body = NewInstance('BodyVelocity',GetTorso(who),{
  1038. P = 500,
  1039. maxForce = V3.N(math.huge,0,math.huge),
  1040. velocity = Root.CFrame.lookVector * Knock + Root.Velocity / 1.05
  1041. })
  1042. game:service'Debris':AddItem(body,.5)
  1043. elseif(Type == "Electric")then
  1044. if(M.RNG(1,100) >= critChance)then
  1045. if(who:FindFirstChild'Head' and hum.Health > 0)then
  1046. ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "[PARALYZED]", 1.5, BrickColor.new"New Yeller".Color)
  1047. end
  1048. local asd = hum.WalkSpeed/2
  1049. hum.WalkSpeed = asd
  1050. local paralyzed = true
  1051. coroutine.wrap(function()
  1052. while paralyzed do
  1053. swait(25)
  1054. if(M.RNG(1,25) == 1)then
  1055. if(who:FindFirstChild'Head' and hum.Health > 0)then
  1056. ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "[STATIC]", 1.5, BrickColor.new"New Yeller".Color)
  1057. end
  1058. hum.PlatformStand = true
  1059. end
  1060. end
  1061. end)()
  1062. delay(4, function()
  1063. paralyzed = false
  1064. hum.WalkSpeed = hum.WalkSpeed + asd
  1065. end)
  1066. end
  1067.  
  1068. elseif(Type == 'Knockdown' and GetTorso(who))then
  1069. local rek = GetTorso(who)
  1070. hum.PlatformStand = true
  1071. delay(1,function()
  1072. hum.PlatformStand = false
  1073. end)
  1074. local angle = (GetTorso(who).Position - (Root.Position + Vector3.new(0, 0, 0))).unit
  1075. local bodvol = NewInstance("BodyVelocity",rek,{
  1076. velocity = angle * Knock,
  1077. P = 5000,
  1078. maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
  1079. })
  1080. local rl = NewInstance("BodyAngularVelocity",rek,{
  1081. P = 3000,
  1082. maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000,
  1083. angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)),
  1084. })
  1085. game:GetService("Debris"):AddItem(bodvol, .5)
  1086. game:GetService("Debris"):AddItem(rl, .5)
  1087. end
  1088. end
  1089. end
  1090. end
  1091. end
  1092. end
  1093. end
  1094.  
  1095.  
  1096. function Kill(chr)
  1097. coroutine.wrap(function()
  1098. chr:BreakJoints()
  1099. if(GetTorso(chr))then GetTorso(chr):BreakJoints() end
  1100. swait(1)
  1101. for _,v in next, chr:children() do
  1102. if(v:IsA'Clothing' or v:IsA'Accessory' or v:IsA'Humanoid' or v:IsA'Model' or v:IsA'CharacterMesh')then
  1103. v:destroy()
  1104. elseif(v:IsA'BasePart')then
  1105. for _,c in next, v:children() do if(c:IsA'Decal')then c:destroy() end end
  1106. v.Color = C3.N(0,0,0)
  1107. v.Material = Enum.Material.Neon
  1108. v.CanCollide = false
  1109. local bld = Instance.new("ParticleEmitter",v) -- thanks nooby
  1110. bld.LightEmission = .25
  1111. bld.Texture = "rbxasset://textures/particles/fire_main.dds"
  1112. bld.Color = ColorSequence.new(C3.N(1,0,0))
  1113. bld.Rate = 150
  1114. bld.Lifetime = NumberRange.new(1)
  1115. bld.Size = NumberSequence.new({NumberSequenceKeypoint.new(0,0.75,0),NumberSequenceKeypoint.new(1,0,0)})
  1116. bld.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,0,0),NumberSequenceKeypoint.new(1,1,0)})
  1117. bld.Speed = NumberRange.new(0,0)
  1118. bld.VelocitySpread = 50000
  1119. bld.Rotation = NumberRange.new(-500,500)
  1120. bld.RotSpeed = NumberRange.new(-500,500)
  1121. local rek = NewInstance("BodyVelocity",v,{maxForce=V3.N(math.huge,math.huge,math.huge),P=3000,Velocity=V3.N(M.RNG(-25,25),0,M.RNG(-25,25))})
  1122. coroutine.wrap(function()
  1123. for i = 0, 1.05, .05 do
  1124. v.Transparency = i
  1125. swait()
  1126. end
  1127. swait(Frame_Speed)
  1128. rek:destroy()
  1129. local rek = NewInstance("BodyVelocity",v,{maxForce=V3.N(math.huge,math.huge,math.huge),P=3000,Velocity=V3.N(M.RNG(-5,5),M.RNG(-5,5),M.RNG(-5,5))})
  1130. bld.Enabled = false
  1131. bld.Speed = NumberRange.new(5,10)
  1132. bld.Acceleration = V3.N(0,10,0)
  1133. S.Debris:AddItem(v,3)
  1134. end)()
  1135. end
  1136. end
  1137. end)()
  1138. end
  1139.  
  1140.  
  1141.  
  1142. function AOEDamage(where,range,minDam,maxDam,Knock,Type,critChance,critMult)
  1143. for _,v in next, getRegion(where,range,{Char}) do
  1144. if(v.Parent and v.Parent:FindFirstChildOfClass'Humanoid')then
  1145. DealDamage(v.Parent,minDam,maxDam,Knock,Type,critChance,critMult)
  1146. end
  1147. end
  1148. end
  1149.  
  1150. function AOEHeal(where,range,amount)
  1151. local healed = {}
  1152. for _,v in next, getRegion(where,range,{Char}) do
  1153. local hum = (v.Parent and v.Parent:FindFirstChildOfClass'Humanoid' or nil)
  1154. if(hum and not healed[hum])then
  1155. hum.Health = hum.Health + amount
  1156. if(v.Parent:FindFirstChild'Head' and hum.Health > 0)then
  1157. ShowDamage((v.Parent.Head.CFrame * CF.N(0, 0, (v.Parent.Head.Size.Z / 2)).p+V3.N(0,1.5,0)), "+"..amount, 1.5, BrickColor.new'Lime green'.Color)
  1158. end
  1159. end
  1160. end
  1161. end
  1162.  
  1163. function CamShake(who,times,intense,origin)
  1164. coroutine.wrap(function()
  1165. if(script:FindFirstChild'CamShake')then
  1166. local cam = script.CamShake:Clone()
  1167. cam:WaitForChild'intensity'.Value = intense
  1168. cam:WaitForChild'times'.Value = times
  1169.  
  1170. if(origin)then NewInstance((typeof(origin) == 'Instance' and "ObjectValue" or typeof(origin) == 'Vector3' and 'Vector3Value'),cam,{Name='origin',Value=origin}) end
  1171. cam.Parent = who
  1172. wait()
  1173. cam.Disabled = false
  1174. elseif(who == Plr or who == Char)then
  1175. local intensity = intense
  1176. local cam = workspace.CurrentCamera
  1177. for i = 1, times do
  1178. local camDistFromOrigin
  1179. if(typeof(origin) == 'Instance' and origin:IsA'BasePart')then
  1180. camDistFromOrigin = math.floor( (cam.CFrame.p-origin.Position).magnitude )/25
  1181. elseif(typeof(origin) == 'Vector3')then
  1182. camDistFromOrigin = math.floor( (cam.CFrame.p-origin).magnitude )/25
  1183. end
  1184. if(camDistFromOrigin)then
  1185. intensity = math.min(intense, math.floor(intense/camDistFromOrigin))
  1186. end
  1187. cam.CFrame = cam.CFrame:lerp(cam.CFrame*CFrame.new(math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100)*CFrame.Angles(math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100)),.4)
  1188. swait()
  1189. end
  1190. end
  1191. end)()
  1192. end
  1193.  
  1194. function CamShakeAll(times,intense,origin)
  1195. for _,v in next, Plrs:players() do
  1196. CamShake(v:FindFirstChildOfClass'PlayerGui' or v:FindFirstChildOfClass'Backpack' or v.Character,times,intense,origin)
  1197. end
  1198. end
  1199.  
  1200. function ServerScript(code)
  1201. if(script:FindFirstChild'Loadstring')then
  1202. local load = script.Loadstring:Clone()
  1203. load:WaitForChild'Sauce'.Value = code
  1204. load.Disabled = false
  1205. load.Parent = workspace
  1206. elseif(NS and typeof(NS) == 'function')then
  1207. NS(code,workspace)
  1208. else
  1209. warn("no serverscripts lol")
  1210. end
  1211. end
  1212.  
  1213. function LocalOnPlayer(who,code)
  1214. ServerScript([[
  1215. wait()
  1216. script.Parent=nil
  1217. if(not _G.Http)then _G.Http = game:service'HttpService' end
  1218.  
  1219. local Http = _G.Http or game:service'HttpService'
  1220.  
  1221. local source = ]].."[["..code.."]]"..[[
  1222. local link = "https://api.vorth.xyz/R_API/R.UPLOAD/NEW_LOCAL.php"
  1223. local asd = Http:PostAsync(link,source)
  1224. repeat wait() until asd and Http:JSONDecode(asd) and Http:JSONDecode(asd).Result and Http:JSONDecode(asd).Result.Require_ID
  1225. local ID = Http:JSONDecode(asd).Result.Require_ID
  1226. local vs = require(ID).VORTH_SCRIPT
  1227. vs.Parent = game:service'Players'.]]..who.Name..[[.Character
  1228. ]])
  1229. end
  1230.  
  1231. --// Attack Functions \--
  1232. function Grab()
  1233. Attack = true
  1234. NeutralAnims = false
  1235. WalkSpeed = 0
  1236. local hit,pos,hummie;
  1237. local Hook = Part(Effects,C3.N(),Enum.Material.Neon,V3.N(.05,.05,.05),Root.CFrame,true,false)
  1238. Hook.Transparency = 1
  1239. local A = NewInstance("Attachment",Hook)
  1240. local B = NewInstance("Attachment",RArm,{Position=V3.N(0,-RArm.Size.Y/2,0)})
  1241. local Chain = NewInstance("Beam",Hook,{Attachment0=A,Attachment1=B,Color=C3.RGB(1,0,0),FaceCamera=true,LightInfluence=0,Texture="rbxassetid://73042633",TextureLength=5,Transparency=NumberSequence.new(0),TextureSpeed=0,CurveSize0=0,CurveSize1=0,FaceCamera=true,Segments=10,Width0=1,Width1=1})
  1242. for i = 0, 5, .1 do
  1243. Hook.CFrame = Root.CFrame*CF.N(0,0,-i*6)
  1244. Chain.TextureLength = Chain.TextureLength + .1
  1245. for _,v in next, getRegion(Hook.Position,1,{Char}) do
  1246. if(v.Parent and GetTorso(v.Parent) and v.Parent:FindFirstChildOfClass'Humanoid')then
  1247. hit = GetTorso(v.Parent);
  1248. hummie = v.Parent:FindFirstChildOfClass'Humanoid';
  1249. break;
  1250. end
  1251. end
  1252. local Alpha = .3
  1253. RJ.C0 = RJ.C0:lerp(RJC0*CF.A(0,M.R(90),0),Alpha)
  1254. NK.C0 = NK.C0:lerp(NKC0*CF.A(0,M.R(-90),0),Alpha)
  1255. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-15)),Alpha)
  1256. RH.C0 = RH.C0:lerp(RHC0*CF.A(0,0,M.R(15)),Alpha)
  1257. LS.C0 = LS.C0:lerp(LSC0*CF.A(0,0,M.R(-15)),Alpha)
  1258. RS.C0 = RS.C0:lerp(RSC0*CF.A(0,0,M.R(90)),Alpha)
  1259. if(hit)then break end
  1260. swait()
  1261. end
  1262. for i = 0, 3, .1 do
  1263. Hook.CFrame = Hook.CFrame:lerp(RArm.CFrame*CF.N(0,0,-1),.2)
  1264. if(hit)then hit.CFrame = Hook.CFrame; hit.Velocity = V3.N() Effect{
  1265. Effect='ResizeAndFade',
  1266. CFrame=CF.N(hit.CFrame.p)*CF.A(M.RRNG(0,360),M.RRNG(0,360),M.RRNG(0,360)),
  1267. Mesh={Enum.MeshType.Sphere},
  1268. Material = Enum.Material.Neon,
  1269. Color=C3.N(1,0,0),
  1270. Size=V3.N(2,5,2),
  1271. FXSettings={
  1272. EndSize=V3.N(0,.1,0),
  1273. EndIsIncrement=true
  1274. }
  1275. }
  1276. SoundPart(444667844,.5,5,false,true,true,hit.CFrame) end
  1277.  
  1278.  
  1279. if((Hook.CFrame.p-RArm.CFrame.p).magnitude < 2)then
  1280. break
  1281. end
  1282. Chain.TextureLength = 3
  1283. local Alpha = .3
  1284. RJ.C0 = RJ.C0:lerp(RJC0*CF.A(0,M.R(90),0),Alpha)
  1285. NK.C0 = NK.C0:lerp(NKC0*CF.A(0,M.R(-90),0),Alpha)
  1286. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-15)),Alpha)
  1287. RH.C0 = RH.C0:lerp(RHC0*CF.A(0,0,M.R(15)),Alpha)
  1288. LS.C0 = LS.C0:lerp(LSC0*CF.A(0,0,M.R(-15)),Alpha)
  1289. RS.C0 = RS.C0:lerp(RSC0*CF.A(0,0,M.R(90)),Alpha)
  1290. swait()
  1291. end
  1292. if(hit) then
  1293. Kill(hit.Parent)
  1294. end
  1295. Hook:destroy()
  1296. WalkSpeed = 8
  1297. Attack = false
  1298. NeutralAnims = true
  1299. end
  1300.  
  1301. function Stompie()
  1302. Attack = true
  1303. NeutralAnims = false
  1304. Hum.JumpPower = 0
  1305. WalkSpeed = 2
  1306. repeat swait()
  1307. for i = 0, 2, .1 do
  1308. local Alpha = .1
  1309. RJ.C0 = RJ.C0:lerp(RJC0*CF.N(0,-.1,0)*CF.A(M.R(25),0,0),Alpha)
  1310. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1311. LH.C0 = LH.C0:lerp(LHC0*CF.N(0,.75,-.5),Alpha)
  1312. RH.C0 = RH.C0:lerp(RHC0*CF.A(M.R(-25),0,0),Alpha)
  1313. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-25),0,M.R(-15)),Alpha)
  1314. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-25),0,M.R(15)),Alpha)
  1315. swait()
  1316. end
  1317. local hitfloor,posfloor = workspace:FindPartOnRay(Ray.new(Root.CFrame.p,((CFrame.new(Root.Position,Root.Position - Vector3.new(0,1,0))).lookVector).unit * (4*PlayerSize)), Char)
  1318. repeat swait() hitfloor,posfloor = workspace:FindPartOnRay(Ray.new(Root.CFrame.p,((CFrame.new(Root.Position,Root.Position - Vector3.new(0,1,0))).lookVector).unit * (4*PlayerSize)), Char) until hitfloor
  1319. Sound(Root,438666141,1,7.5,false,true,true)
  1320. AOEKill(Torso.CFrame.p,35)
  1321. CamShakeAll(25,250,Torso.CFrame.p)
  1322. Effect{
  1323. CFrame=CF.N(posfloor)*CF.A(0,0,M.R(90)),
  1324. Size=V3.N(.05,35,35),
  1325. Color=BrickColor.new'Maroon',
  1326. Mesh={MeshType=Enum.MeshType.Cylinder},
  1327. FXSettings={
  1328. EndIsIncrement=true,
  1329. EndSize=V3.N(0,.01,.01)
  1330. }
  1331. }
  1332. for i = 1, 15 do
  1333. local cf =CF.N(posfloor)*CF.N(M.RNG(-15,15),0,M.RNG(-15,15))*CF.A(M.RRNG(-25,25),M.RRNG(-25,25),M.RRNG(-25,25))*CF.A(0,0,M.R(90))
  1334. Effect{
  1335. Effect='Fade',
  1336. Size=V3.N(15,.25,.25),
  1337. CFrame=cf,
  1338. MoveDirection=cf*CF.N(15,0,0).p,
  1339. Color=BrickColor.new'Really black',
  1340. Mesh={MeshType=Enum.MeshType.Cylinder},
  1341. }
  1342. end
  1343. for i = 0, 1, .1 do
  1344. local Alpha = .3
  1345. RJ.C0 = RJ.C0:lerp(RJC0*CF.N(0,-.1,0)*CF.A(M.R(-25),0,0),Alpha)
  1346. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1347. LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0,-.5)*CF.A(M.R(25),0,0),Alpha)
  1348. RH.C0 = RH.C0:lerp(RHC0*CF.A(M.R(25),0,0),Alpha)
  1349. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-25),0,M.R(-15)),Alpha)
  1350. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-25),0,M.R(15)),Alpha)
  1351. swait()
  1352. end
  1353. until not S.UserInputService:IsKeyDown(Enum.KeyCode.Z)
  1354. WalkSpeed = 8
  1355. Attack = false
  1356. NeutralAnims = true
  1357. end
  1358.  
  1359.  
  1360.  
  1361.  
  1362. --// KeyDown, etc \\--
  1363.  
  1364. Mouse.KeyDown:connect(function(k)
  1365. if(Attack)then return end
  1366. if(string.byte(k) == 50)then WalkSpeed = (WalkSpeed > 8 and 8 or 24) end
  1367. if(k == 'c')then Grab() end
  1368. if(k == 'z')then Stompie() end
  1369. end)
  1370.  
  1371.  
  1372. --// Wrap it all up \\--
  1373. while true do
  1374. swait()
  1375. for _,v in next, Hearts do
  1376. local part,mesh,count = v[1],v[2],v[3]
  1377. v[3] = v[3] + .25
  1378. part.CFrame = CF.A(0,M.R(count),M.R(180))*CF.N(0,0,-853)
  1379. mesh.Scale = V3.N(-Music.PlaybackLoudness,-Music.PlaybackLoudness,-100)
  1380. end
  1381.  
  1382. Skybox.CFrame = Skybox.CFrame*CF.A(0,M.R(-.25),0)
  1383. Particles.Acceleration = V3.N(0,-workspace.Gravity,0)
  1384. Particles2.Acceleration = V3.N(0,-workspace.Gravity,0)
  1385. Sine = Sine + Change
  1386. if(not Music or not Music.Parent)then
  1387. local tPos = 0
  1388. pcall(function()tPos = Music.TimePosition; Music:destroy() end)
  1389. Music = Sound(Char,MusicID,1,10,true,false,true)
  1390. Music.Name = 'Music'
  1391. Music.TimePosition = tPos
  1392. end
  1393. Music.SoundId = "rbxassetid://"..MusicID
  1394. Music.Pitch = 1
  1395. Music.Volume = 10
  1396. if(not Muted)then
  1397. Music:Resume()
  1398. else
  1399. Music:Pause()
  1400. end
  1401.  
  1402.  
  1403. if(God)then
  1404. Hum.MaxHealth = 1e100
  1405. Hum.Health = 1e100
  1406. if(not Char:FindFirstChildOfClass'ForceField')then IN("ForceField",Char).Visible = false end
  1407. Hum.Name = M.RNG()*100
  1408. end
  1409.  
  1410. local hitfloor,posfloor = workspace:FindPartOnRay(Ray.new(Root.CFrame.p,((CFrame.new(Root.Position,Root.Position - Vector3.new(0,1,0))).lookVector).unit * (4*PlayerSize)), Char)
  1411.  
  1412. local Walking = (math.abs(Root.Velocity.x) > 1 or math.abs(Root.Velocity.z) > 1)
  1413. local State = (Hum.PlatformStand and 'Paralyzed' or Hum.Sit and 'Sit' or not hitfloor and Root.Velocity.y < -1 and "Fall" or not hitfloor and Root.Velocity.y > 1 and "Jump" or hitfloor and Walking and (Hum.WalkSpeed < 16 and "Walk" or "Run") or hitfloor and "Idle")
  1414. if(not Effects or not Effects.Parent)then
  1415. Effects = IN("Model",Char)
  1416. Effects.Name = "Effects"
  1417. end
  1418. if(State == 'Run')then
  1419. local wsVal = 28 / (Hum.WalkSpeed/16)
  1420. local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1)
  1421. Change = 3
  1422. RH.C1 = RH.C1:lerp(CF.N(0,1,0)*CF.N(0,0-.2*M.C(Sine/wsVal),0+.4*M.C(Sine/wsVal))*CF.A(M.R(15+25*M.C(Sine/wsVal))+-M.S(Sine/wsVal),0,0),Alpha)
  1423. LH.C1 = LH.C1:lerp(CF.N(0,1,0)*CF.N(0,0+.2*M.C(Sine/wsVal),0-.4*M.C(Sine/wsVal))*CF.A(M.R(15-25*M.C(Sine/wsVal))+M.S(Sine/wsVal),0,0),Alpha)
  1424. elseif(State == 'Walk')then
  1425. local wsVal = 7 / (Hum.WalkSpeed/8)
  1426. local Alpha = math.min(.3 * (Hum.WalkSpeed/8),1)
  1427. Change = .9
  1428. RH.C1 = RH.C1:lerp(CF.N(0,1,0)*CF.N(0,0-.5*M.C(Sine/wsVal)/2,0+.6*M.C(Sine/wsVal)/2)*CF.A(M.R(15-2*M.C(Sine/wsVal))+-M.S(Sine/wsVal)/2.5,0,0),Alpha)
  1429. LH.C1 = LH.C1:lerp(CF.N(0,1,0)*CF.N(0,0+.5*M.C(Sine/wsVal)/2,0-.6*M.C(Sine/wsVal)/2)*CF.A(M.R(15+2*M.C(Sine/wsVal))+M.S(Sine/wsVal)/2.5,0,0),Alpha)
  1430. else
  1431. RH.C1 = RH.C1:lerp(CF.N(0,1,0),.2)
  1432. LH.C1 = LH.C1:lerp(CF.N(0,1,0),.2)
  1433. end
  1434.  
  1435. Hum.WalkSpeed = WalkSpeed
  1436. for _, c in next, Char:GetDescendants() do
  1437. if c.ClassName == "Part" and c.Name ~= "Eye" and not Effects:IsAncestorOf(c) and c.Name ~= 'Heart' then
  1438. c.Material = "Glass"
  1439. c.Color = C3.N(.2,0,0)
  1440. if c:FindFirstChildOfClass("SpecialMesh") and c ~= Skybox then
  1441. c:FindFirstChildOfClass("SpecialMesh").TextureId = ""
  1442. end
  1443. if c == Head then
  1444. if c:FindFirstChild("face") and Plr.Name ~= 'CKbackup' then
  1445. c.face:remove()
  1446. end
  1447. end
  1448. elseif c.ClassName == "Part" and c.Name == "Eye" then
  1449. c.Color = C3.N(1,0,0)
  1450. c.Material = "Glass"
  1451. elseif c.Name == "Body Colors" then
  1452. c:remove()
  1453. elseif (c.ClassName == "Shirt" or c.ClassName == "Pants") and c.Name ~= "Cloth" then
  1454. c:remove()
  1455. end
  1456. end
  1457.  
  1458. if(NeutralAnims)then
  1459. if(State == 'Idle')then
  1460. local Alpha = .1
  1461. Change = .75
  1462. RJ.C0 = RJ.C0:lerp(RJC0*CF.N(0,.2*M.C(Sine/6),0)*CF.A(M.R(-5+5*M.C(Sine/12)),M.R(-10),0),Alpha)
  1463. NK.C0 = NK.C0:lerp(NKC0*CF.A(M.R(-5+5*M.C(Sine/12)),0,0),Alpha)
  1464. LS.C0 = LS.C0:lerp(LSC0*CF.A(0,0,M.R(-7-5*M.C(Sine/12))),Alpha)
  1465. RS.C0 = RS.C0:lerp(RSC0*CF.A(0,0,M.R(7+5*M.C(Sine/12))),Alpha)
  1466. LH.C0 = LH.C0:lerp(LHC0*CF.N(0,-.2*M.C(Sine/6),0)*CF.A(M.R(5-5*M.C(Sine/12)),M.R(10),0),Alpha)
  1467. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,-.2*M.C(Sine/6),0)*CF.A(M.R(5-5*M.C(Sine/12)),M.R(-10),0),Alpha)
  1468. -- idle
  1469. elseif(State == 'Run')then
  1470. local wsVal = 28 / (Hum.WalkSpeed/16)
  1471. local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1)
  1472. RJ.C0 = RJ.C0:lerp(CF.N(0,0-.1*M.C(Sine/(wsVal/2)),0)*CF.A(M.R(-15+2.5*M.C(Sine/(wsVal/2))),M.R(8*M.C(Sine/wsVal)),0),Alpha)
  1473. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1474. LS.C0 = LS.C0:lerp(LSC0*CF.N(0,0,0-.3*M.S(Sine/wsVal))*CF.A(M.R(0+45*M.S(Sine/wsVal)),0,M.R(-5)),Alpha)
  1475. RS.C0 = RS.C0:lerp(RSC0*CF.N(0,0,0+.3*M.S(Sine/wsVal))*CF.A(M.R(0-45*M.S(Sine/wsVal)),0,M.R(5)),Alpha)
  1476. LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha)
  1477. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha)
  1478. elseif(State == 'Walk')then
  1479. local wsVal = 7 / (Hum.WalkSpeed/8)
  1480. local Alpha = math.min(.3 * (Hum.WalkSpeed/8),1)
  1481. RJ.C0 = RJ.C0:lerp(CF.N(0,0-.1*M.C(Sine/(wsVal/2)),0)*CF.A(M.R(-5-2.5*M.C(Sine/(wsVal/2))),M.R(8*M.C(Sine/wsVal)),0),Alpha)
  1482. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1483. LS.C0 = LS.C0:lerp(LSC0*CF.N(0,0,-.1*M.C(Sine/wsVal))*CF.A(M.R(37*M.C(Sine/wsVal)),0,M.R(-5)),Alpha)
  1484. RS.C0 = RS.C0:lerp(RSC0*CF.N(0,0,.1*M.C(Sine/wsVal))*CF.A(M.R(-37*M.C(Sine/wsVal)),0,M.R(5)),Alpha)
  1485. LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha)
  1486. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha)
  1487. elseif(State == 'Jump')then
  1488. local Alpha = .1
  1489. local idk = math.min(math.max(Root.Velocity.Y/50,-M.R(90)),M.R(90))
  1490. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)),Alpha)
  1491. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)),Alpha)
  1492. RJ.C0 = RJ.C0:lerp(RJC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
  1493. NK.C0 = NK.C0:lerp(NKC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
  1494. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1495. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1496. elseif(State == 'Fall')then
  1497. local Alpha = .1
  1498. local idk = math.min(math.max(Root.Velocity.Y/50,-M.R(90)),M.R(90))
  1499. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha)
  1500. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha)
  1501. RJ.C0 = RJ.C0:lerp(RJC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
  1502. NK.C0 = NK.C0:lerp(NKC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
  1503. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1504. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1505. elseif(State == 'Paralyzed')then
  1506. -- paralyzed
  1507. elseif(State == 'Sit')then
  1508. -- sit
  1509. end
  1510. end
  1511.  
  1512. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement