Advertisement
PowerSans124

Chara

Jul 10th, 2018
154
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VBScript 73.60 KB | None | 0 0
  1. -- Created by Nebula_Zorua --
  2. -- Your DeTERMINATION --
  3. -- Y o u  a c t  l i k e  y o u  h a v e  a  c h o i c e. =) --
  4. -- Discord: Nebula the Zorua#6969
  5. -- Youtube: https://www.youtube.com/channel/UCo9oU9dCw8jnuVLuy4_SATA
  6.  
  7.  
  8. --// Initializing \\--
  9. local S = setmetatable({},{__index = function(s,i) return game:service(i) end})
  10. local Plrs = S.Players
  11. local Plr = Plrs.LocalPlayer
  12. local Char = Plr.Character
  13. local Hum = Char:FindFirstChildOfClass'Humanoid'
  14. local RArm = Char["Right Arm"]
  15. local LArm = Char["Left Arm"]
  16. local RLeg = Char["Right Leg"]
  17. local LLeg = Char["Left Leg"]  
  18. local Root = Char:FindFirstChild'HumanoidRootPart'
  19. local Torso = Char.Torso
  20. local Head = Char.Head
  21. local NeutralAnims = true
  22. local Attack = false
  23. local BloodPuddles = {}
  24. local Effects = {}
  25. local Debounces = {Debounces={}}
  26. local Mouse = Plr:GetMouse()
  27. local Hit = {}
  28. local Sine = 0
  29. local Change = 1
  30. local Souls = 0
  31. --// Wings \\--
  32. --bird wings Gifted by harrypotterfan249, Local Script!
  33. --Jump Two Time
  34. --Down Press Q
  35.  
  36. script.Parent = nil
  37.  
  38. function fly()
  39.  
  40. for i,v in pairs(script:GetChildren()) do
  41.  
  42.         pcall(function() v.Value = "" end)
  43.  
  44.         game:GetService("Debris"):AddItem(v,.1)
  45.  
  46. end
  47.  
  48. function weld(p0,p1,c0,c1,par)
  49.  
  50.         local w = Instance.new("Weld",p0 or par)
  51.  
  52.         w.Part0 = p0
  53.  
  54.         w.Part1 = p1
  55.  
  56.         w.C0 = c0 or CFrame.new()
  57.  
  58.         w.C1 = c1 or CFrame.new()
  59.  
  60.         return w
  61.  
  62. end
  63.  
  64. local motors = {}
  65.  
  66. function motor(p0,p1,c0,c1,des,vel,par)
  67.  
  68.         local w = Instance.new("Motor6D",p0 or par)
  69.  
  70.         w.Part0 = p0
  71.  
  72.         w.Part1 = p1
  73.  
  74.         w.C0 = c0 or CFrame.new()
  75.  
  76.         w.C1 = c1 or CFrame.new()
  77.  
  78.         w.MaxVelocity = tonumber(vel) or .05
  79.  
  80.         w.DesiredAngle = tonumber(des) or 0
  81.  
  82.         return w
  83.  
  84. end
  85.  
  86. function lerp(a,b,c)
  87.  
  88.     return a+(b-a)*c
  89.  
  90. end
  91.  
  92. function clerp(c1,c2,al)
  93.  
  94.         local com1 = {c1.X,c1.Y,c1.Z,c1:toEulerAnglesXYZ()}
  95.  
  96.         local com2 = {c2.X,c2.Y,c2.Z,c2:toEulerAnglesXYZ()}
  97.  
  98.         for i,v in pairs(com1) do
  99.  
  100.                 com1[i] = lerp(v,com2[i],al)
  101.  
  102.         end
  103.  
  104.         return CFrame.new(com1[1],com1[2],com1[3]) * CFrame.Angles(select(4,unpack(com1)))
  105.  
  106. end
  107.  
  108. function ccomplerp(c1,c2,al)
  109.  
  110.         local com1 = {c1:components()}
  111.  
  112.         local com2 = {c2:components()}
  113.  
  114.         for i,v in pairs(com1) do
  115.  
  116.                 com1[i] = lerp(v,com2[i],al)
  117.  
  118.         end
  119.  
  120.         return CFrame.new(unpack(com1))
  121.  
  122. end
  123.  
  124. function tickwave(time,length,offset)
  125.  
  126.         return (math.abs((tick()+(offset or 0))%time-time/2)*2-time/2)/time/2*length
  127.  
  128. end
  129.  
  130. function invcol(c)
  131.  
  132.         c = c.Color
  133.  
  134.         return BrickColor.new(Color3.new(1-c.b,1-c.g,1-c.r))
  135.  
  136. end
  137.  
  138. local oc = oc or function(...) return ... end
  139.  
  140. local plr = game.Players.LocalPlayer
  141.  
  142. local char = plr.Character
  143.  
  144. local tor = char.Torso
  145.  
  146. local hum = char.Humanoid
  147.  
  148. hum.PlatformStand = false
  149.  
  150. pcall(function()
  151.  
  152.         char.Wings:Destroy()
  153.  
  154. end)
  155.  
  156. pcall(function()
  157.  
  158.         char.Angel:Destroy() -- hat
  159.  
  160. end)
  161.  
  162. local mod = Instance.new("Model",char)
  163.  
  164. mod.Name = "Wings"
  165.  
  166. local special = {
  167.  
  168.         --antiboomz0r = {"Really black","Institutional white",0,0,false,Color3.new(1,1,.95),Color3.new(1,1,.6)},
  169.  
  170.         antiboomz0r = {"New Yeller",nil,0.4,0.7,true,Color3.new(1,1,.95),Color3.new(1,1,.6)},
  171.  
  172.         --antiboomz0r = {"Cyan","Toothpaste",0,0,false,Color3.new(1,0,0),Color3.new(0,0,0)},
  173.  
  174.         taart = {"Royal purple",nil,.4,.4,true},
  175.  
  176.         mitta = {"Black",nil,0,0,false},
  177.  
  178.         penjuin3 = {"White",nil,0,0,false},
  179.  
  180.         thepc8110 = {"Black","Bright red",.5,0,false,Color3.new(1,0,0),Color3.new(0,0,0)},
  181.  
  182.         nonspeaker = {"Cyan","Toothpaste",0,0,false,Color3.new(1,0,0),Color3.new(0,0,0)},
  183.  
  184.         littleau999 = {"Reddish brown",1030,0,0,false},
  185.  
  186.         unscripter = {"Really black","Really black",.2,0,true,Color3.new(0,0,0),Color3.new(0,0,0)},
  187.  
  188.         oxcool1 = {"Really black","White",.2,0,false,Color3.new(0,0,0),Color3.new(0,0,0)},
  189.  
  190.         krodmiss = {"Really black",nil,0,0,false},
  191.  
  192. }
  193.  
  194. local topcolor = invcol(char.Torso.BrickColor)
  195.  
  196. local feacolor = char.Torso.BrickColor
  197.  
  198. local ptrans = 0
  199.  
  200. local pref = 0
  201.  
  202. local fire = false
  203.  
  204. local fmcol = Color3.new()
  205.  
  206. local fscol = Color3.new()
  207.  
  208. local spec = special[plr.Name:lower()]
  209.  
  210. if spec then
  211.  
  212.         topcolor,feacolor,ptrans,pref,fire,fmcol,fscol = spec[1] and BrickColor.new(spec[1]) or topcolor,spec[2] and BrickColor.new(spec[2]) or feacolor,spec[3],spec[4],spec[5],spec[6],spec[7]
  213.  
  214. end
  215.  
  216. local part = Instance.new("Part")
  217.  
  218. part.FormFactor = "Custom"
  219.  
  220. part.Size = Vector3.new(.2,.2,.2)
  221.  
  222. part.TopSurface,part.BottomSurface = 0,0
  223.  
  224. part.CanCollide = false
  225.  
  226. part.BrickColor = topcolor
  227.  
  228. part.Transparency = ptrans
  229.  
  230. part.Reflectance = pref
  231.  
  232. local ef = Instance.new("Fire",fire and part or nil)
  233.  
  234. ef.Size = .15
  235.  
  236. ef.Color = fmcol or Color3.new()
  237.  
  238. ef.SecondaryColor = fscol or Color3.new()
  239.  
  240. part:BreakJoints()
  241.  
  242.  
  243. function newpart()
  244.  
  245.         local clone = part:Clone()
  246.  
  247.         clone.Parent = mod
  248.  
  249.         clone:BreakJoints()
  250.  
  251.         return clone
  252.  
  253. end
  254.  
  255. local feath = newpart()
  256.  
  257. feath.BrickColor = feacolor
  258.  
  259. feath.Transparency = 0
  260.  
  261. Instance.new("SpecialMesh",feath).MeshType = "Sphere"
  262.  
  263. function newfeather()
  264.  
  265.         local clone = feath:Clone()
  266.  
  267.         clone.Parent = mod
  268.  
  269.         clone:BreakJoints()
  270.  
  271.         return clone
  272.  
  273. end
  274.  
  275.  
  276. ---------- RIGHT WING
  277.  
  278. local r1 = newpart()
  279.  
  280. r1.Size = Vector3.new(.3,1.5,.3)*1.2
  281.  
  282. local rm1 = motor(tor,r1,CFrame.new(.35,.6,.4) * CFrame.Angles(0,0,math.rad(-60)) * CFrame.Angles(math.rad(30),math.rad(-25),0),CFrame.new(0,-.8,0),.1)
  283.  
  284. local r2 = newpart()
  285.  
  286. r2.Size = Vector3.new(.4,1.8,.4)*1.2
  287.  
  288. local rm2 = motor(r1,r2,CFrame.new(0,.75,0) * CFrame.Angles(0,0,math.rad(50)) * CFrame.Angles(math.rad(-30),math.rad(15),0),CFrame.new(0,-.9,0),.1)
  289.  
  290. local r3 = newpart()
  291.  
  292. r3.Size = Vector3.new(.3,2.2,.3)*1.2
  293.  
  294. local rm3 = motor(r2,r3,CFrame.new(.1,.9,0) * CFrame.Angles(0,0,math.rad(-140)) * CFrame.Angles(math.rad(-3),0,0),CFrame.new(0,-1.1,0),.1)
  295.  
  296. local r4 = newpart()
  297.  
  298. r4.Size = Vector3.new(.25,1.2,.25)*1.2
  299.  
  300. local rm4 = motor(r3,r4,CFrame.new(0,1.1,0) * CFrame.Angles(0,0,math.rad(-10)) * CFrame.Angles(math.rad(-3),0,0),CFrame.new(0,-.6,0),.1)
  301.  
  302. local feather = newfeather()
  303.  
  304. feather.Mesh.Scale = Vector3.new(1,1,1)
  305.  
  306. feather.Size = Vector3.new(.4,3,.3)
  307.  
  308. weld(r4,feather,CFrame.new(-.1,-.3,0),CFrame.new(0,-1.5,0))
  309.  
  310. feather = newfeather()
  311.  
  312. feather.Mesh.Scale = Vector3.new(1,1,1)
  313.  
  314. feather.Size = Vector3.new(.4,2.3,.3)
  315.  
  316. weld(r4,feather,CFrame.new(.1,-.1,0) * CFrame.Angles(0,math.random()*.1,0),CFrame.new(0,-1.1,0))
  317.  
  318. feather = newfeather()
  319.  
  320. feather.Mesh.Scale = Vector3.new(1,1,1)
  321.  
  322. feather.Size = Vector3.new(.35,2.2,.25)
  323.  
  324. weld(r4,feather,CFrame.new(.1,-.3,0) * CFrame.Angles(0,math.random()*.1,math.rad(-10)),CFrame.new(0,-1.1,0))
  325.  
  326. local rf3 = {}
  327.  
  328. for i=0,7 do
  329.  
  330.         feather = newfeather()
  331.  
  332.         feather.Mesh.Scale = Vector3.new(1,1,1)
  333.  
  334.         feather.Size = Vector3.new(.45,2.2,.35)
  335.  
  336.         table.insert(rf3,motor(r3,feather,CFrame.new(.05,1-i*.285,0) * CFrame.Angles(0,math.random()*.1,math.rad(-25-i*2)),CFrame.new(0,-feather.Size.Y/2,0)))
  337.  
  338. end
  339.  
  340. local rf2 = {}
  341.  
  342. for i=0,6 do
  343.  
  344.         feather = newfeather()
  345.  
  346.         feather.Mesh.Scale = Vector3.new(1,1,1)
  347.  
  348.         feather.Size = Vector3.new(.45,2.2-i*.08,.3)
  349.  
  350.         table.insert(rf2,motor(r2,feather,CFrame.new(.05,.75-i*.26,0) * CFrame.Angles(0,math.random()*.1,math.rad(-75-i*4)),CFrame.new(0,-feather.Size.Y/2,0)))
  351.  
  352. end
  353.  
  354. local rf1 = {}
  355.  
  356. for i=0,6 do
  357.  
  358.         feather = newfeather()
  359.  
  360.         feather.Mesh.Scale = Vector3.new(1,1,1)
  361.  
  362.         feather.Size = Vector3.new(.37,1.65-i*.06,.25)
  363.  
  364.         table.insert(rf1,motor(r1,feather,CFrame.new(.05,.63-i*.21,0) * CFrame.Angles(0,math.random()*.05,math.rad(-75)),CFrame.new(0,-feather.Size.Y/2,0)))
  365.  
  366. end
  367.  
  368. ---------- LEFT WING
  369.  
  370. local l1 = newpart()
  371.  
  372. l1.Size = Vector3.new(.3,1.5,.3)*1.2
  373.  
  374. local lm1 = motor(tor,l1,CFrame.new(-.35,.6,.4) * CFrame.Angles(0,0,math.rad(60)) * CFrame.Angles(math.rad(30),math.rad(25),0) * CFrame.Angles(0,-math.pi,0),CFrame.new(0,-.8,0) ,.1)
  375.  
  376. local l2 = newpart()
  377.  
  378. l2.Size = Vector3.new(.4,1.8,.4)*1.2
  379.  
  380. local lm2 = motor(l1,l2,CFrame.new(0,.75,0) * CFrame.Angles(0,0,math.rad(50)) * CFrame.Angles(math.rad(30),math.rad(-15),0),CFrame.new(0,-.9,0),.1)
  381.  
  382. local l3 = newpart()
  383.  
  384. l3.Size = Vector3.new(.3,2.2,.3)*1.2
  385.  
  386. local lm3 = motor(l2,l3,CFrame.new(.1,.9,0) * CFrame.Angles(0,0,math.rad(-140)) * CFrame.Angles(math.rad(3),0,0),CFrame.new(0,-1.1,0),.1)
  387.  
  388. local l4 = newpart()
  389.  
  390. l4.Size = Vector3.new(.25,1.2,.25)*1.2
  391.  
  392. local lm4 = motor(l3,l4,CFrame.new(0,1.1,0) * CFrame.Angles(0,0,math.rad(-10)) * CFrame.Angles(math.rad(3),0,0),CFrame.new(0,-.6,0),.1)
  393.  
  394. local feather = newfeather()
  395.  
  396. feather.Mesh.Scale = Vector3.new(1,1,1)
  397.  
  398. feather.Size = Vector3.new(.4,3,.3)
  399.  
  400. weld(l4,feather,CFrame.new(-.1,-.3,0),CFrame.new(0,-1.5,0))
  401.  
  402. feather = newfeather()
  403.  
  404. feather.Mesh.Scale = Vector3.new(1,1,1)
  405.  
  406. feather.Size = Vector3.new(.4,2.3,.3)
  407.  
  408. weld(l4,feather,CFrame.new(.1,-.1,0) * CFrame.Angles(0,math.random()*.1,0),CFrame.new(0,-1.1,0))
  409.  
  410. feather = newfeather()
  411.  
  412. feather.Mesh.Scale = Vector3.new(1,1,1)
  413.  
  414. feather.Size = Vector3.new(.35,2.2,.25)
  415.  
  416. weld(l4,feather,CFrame.new(.1,-.3,0) * CFrame.Angles(0,math.random()*.1,math.rad(-10)),CFrame.new(0,-1.1,0))
  417.  
  418. local lf3 = {}
  419.  
  420. for i=0,7 do
  421.  
  422.         feather = newfeather()
  423.  
  424.         feather.Mesh.Scale = Vector3.new(1,1,1)
  425.  
  426.         feather.Size = Vector3.new(.45,2.2,.35)
  427.  
  428.         table.insert(lf3,motor(l3,feather,CFrame.new(.05,1-i*.285,0) * CFrame.Angles(0,math.random()*.1,math.rad(-25-i*2)),CFrame.new(0,-feather.Size.Y/2,0)))
  429.  
  430. end
  431.  
  432. local lf2 = {}
  433.  
  434. for i=0,6 do
  435.  
  436.         feather = newfeather()
  437.  
  438.         feather.Mesh.Scale = Vector3.new(1,1,1)
  439.  
  440.         feather.Size = Vector3.new(.45,2.2-i*.08,.3)
  441.  
  442.         table.insert(lf2,motor(l2,feather,CFrame.new(.05,.75-i*.26,0) * CFrame.Angles(0,math.random()*.1,math.rad(-75-i*4)),CFrame.new(0,-feather.Size.Y/2,0)))
  443.  
  444. end
  445.  
  446. local lf1 = {}
  447.  
  448. for i=0,6 do
  449.  
  450.         feather = newfeather()
  451.  
  452.         feather.Mesh.Scale = Vector3.new(1,1,1)
  453.  
  454.         feather.Size = Vector3.new(.37,1.65-i*.06,.25)
  455.  
  456.         table.insert(lf1,motor(l1,feather,CFrame.new(.05,.63-i*.21,0) * CFrame.Angles(0,math.random()*.05,math.rad(-75)),CFrame.new(0,-feather.Size.Y/2,0)))
  457.  
  458. end
  459.  
  460. local rwing = {rm1,rm2,rm3,rm4}
  461.  
  462. local lwing = {lm1,lm2,lm3,lm4}
  463.  
  464. local oc0 = {}
  465.  
  466. for i,v in pairs(rwing) do
  467.  
  468.         oc0[v] = v.C0
  469.  
  470. end
  471.  
  472. for i,v in pairs(lwing) do
  473.  
  474.         oc0[v] = v.C0
  475.  
  476. end
  477.  
  478. function gotResized()
  479.  
  480.         if lastsize then
  481.  
  482.                 if tor.Size == lastsize then return end -- This shouldn't happen?
  483.  
  484.                 local scaleVec = tor.Size/lastsize
  485.  
  486.                 for i,v in pairs(oc0) do
  487.  
  488.                         oc0[i] = v-v.p+scaleVec*v.p
  489.  
  490.                 end
  491.  
  492.                 lastsize = tor.Size
  493.  
  494.         end
  495.  
  496.         lastsize = tor.Size
  497.  
  498. end
  499.  
  500. tor.Changed:connect(function(p)
  501.  
  502.         if p == "Size" then
  503.  
  504.                 gotResized()
  505.  
  506.         end
  507.  
  508. end)
  509.  
  510. gotResized()
  511.  
  512. local idle = {0,0.5,-.2,0; .05,.05,.1,.05; -.6,-1.5,.1,0;}--0,.3,0,0
  513.  
  514. local outlow = {-.7,-.2,1.8,0; .3,.05,.1,.05; .2,0,0,0}
  515.  
  516. local outhigh = {.5,-.2,1.8,0; .3,.05,.1,.05; .2,0,0,0}
  517.  
  518. local veryhigh = {.9,-.3,1.9,0; .3,.05,.1,.05; .2,0,0,0}
  519.  
  520. local flap1 = {-.3,.3,1.1,-.2; .3,.05,.1,.05; .2,-.6,0,0}
  521.  
  522. local divebomb = {0,.2,.4,-.7; .3,.05,.1,.05; 0,-.5,-.6,0}
  523.  
  524.  
  525. function setwings(tab,time)
  526.  
  527.         time = time or 10
  528.  
  529.         for i=1,4 do
  530.  
  531.                 rwing[i].DesiredAngle = tab[i]
  532.  
  533.                 lwing[i].DesiredAngle = tab[i]
  534.  
  535.                 rwing[i].MaxVelocity = math.abs(tab[i]-rwing[i].CurrentAngle)/time
  536.  
  537.                 lwing[i].MaxVelocity = math.abs(tab[i]-lwing[i].CurrentAngle)/time
  538.  
  539.                 local rcf = oc0[rwing[i]] * (tab[12+i] or CFrame.new())
  540.  
  541.                 local lcf = oc0[lwing[i]] * (tab[12+i] or CFrame.new())
  542.  
  543.         end
  544.  
  545.         for i,v in pairs(rf1) do
  546.  
  547.                 v.DesiredAngle = tab[9]
  548.  
  549.                 v.MaxVelocity = math.abs(v.DesiredAngle-v.CurrentAngle)/time
  550.  
  551.         end
  552.  
  553.         for i,v in pairs(lf1) do
  554.  
  555.                 v.DesiredAngle = tab[9]
  556.  
  557.                 v.MaxVelocity = math.abs(v.DesiredAngle-v.CurrentAngle)/time
  558.  
  559.         end
  560.  
  561.         for i,v in pairs(rf2) do
  562.  
  563.                 v.DesiredAngle = tab[10]
  564.  
  565.                 v.MaxVelocity = math.abs(v.DesiredAngle-v.CurrentAngle)/time
  566.  
  567.         end
  568.  
  569.         for i,v in pairs(lf2) do
  570.  
  571.                 v.DesiredAngle = tab[10]
  572.  
  573.                 v.MaxVelocity = math.abs(v.DesiredAngle-v.CurrentAngle)/time
  574.  
  575.         end
  576.  
  577.         for i,v in pairs(rf3) do
  578.  
  579.                 v.DesiredAngle = tab[11]
  580.  
  581.                 v.MaxVelocity = math.abs(v.DesiredAngle-v.CurrentAngle)/time
  582.  
  583.         end
  584.  
  585.         for i,v in pairs(lf3) do
  586.  
  587.                 v.DesiredAngle = tab[11]
  588.  
  589.                 v.MaxVelocity = math.abs(v.DesiredAngle-v.CurrentAngle)/time
  590.  
  591.         end
  592.  
  593. end
  594.  
  595. setwings(outhigh,1)
  596.  
  597. flying = false
  598.  
  599. moving = false
  600.  
  601. for i,v in pairs(tor:GetChildren()) do
  602.  
  603.         if v.ClassName:lower():match("body") then
  604.  
  605.                 v:Destroy()
  606.  
  607.         end
  608.  
  609. end
  610.  
  611. local ctor = tor:Clone()
  612.  
  613. ctor:ClearAllChildren()
  614.  
  615. ctor.Name = "cTorso"
  616.  
  617. ctor.Transparency = 1
  618.  
  619. ctor.CanCollide = false
  620.  
  621. ctor.FormFactor = "Custom"
  622.  
  623. ctor.Size = Vector3.new(.2,.2,.2)
  624.  
  625. ctor.Parent = mod
  626.  
  627. weld(tor,ctor)
  628.  
  629. local bg = Instance.new("BodyGyro",ctor)
  630.  
  631. bg.maxTorque = Vector3.new()
  632.  
  633. bg.P = 15000
  634.  
  635. bg.D = 1000
  636.  
  637. local bv = Instance.new("BodyVelocity",ctor)
  638.  
  639. bv.maxForce = Vector3.new()
  640.  
  641. bv.P = 15000
  642.  
  643. vel = Vector3.new()
  644.  
  645. cf = CFrame.new()
  646.  
  647. flspd = 0
  648.  
  649.  
  650. keysdown = {}
  651.  
  652. keypressed = {}
  653.  
  654. ktime = {}
  655.  
  656. descendtimer = 0
  657.  
  658. jumptime = tick()
  659.  
  660. hum.Jumping:connect(function()
  661.  
  662.         jumptime = tick()
  663.  
  664. end)
  665.  
  666. cam = workspace.CurrentCamera
  667.  
  668. kd = plr:GetMouse().KeyDown:connect(oc(function(key)
  669.  
  670.         keysdown[key] = true
  671.  
  672.         keypressed[key] = true
  673.  
  674.         if key == "q" then
  675.  
  676.                 descendtimer = tick()
  677.  
  678.         elseif key == " " and not hum.Jump then
  679.  
  680.                 jumptime = tick()
  681.  
  682.         elseif (key == "a" or key == "d") and ktime[key] and tick()-ktime[key] < .3 and math.abs(reqrotx) < .3 then
  683.  
  684.                 reqrotx = key == "a" and math.pi*2 or -math.pi*2
  685.  
  686.         end
  687.  
  688.         ktime[key] = tick()
  689.  
  690. end))
  691.  
  692. ku = plr:GetMouse().KeyUp:connect(function(key)
  693.  
  694.         keysdown[key] = false
  695.  
  696.         if key == " " then
  697.  
  698.                 descendtimer = tick()
  699.  
  700.         end
  701.  
  702. end)
  703.  
  704. function mid(a,b,c)
  705.  
  706.         return math.max(a,math.min(b,c or -a))
  707.  
  708. end
  709.  
  710. function bn(a)
  711.  
  712.         return a and 1 or 0
  713.  
  714. end
  715.  
  716. function gm(tar)
  717.  
  718.         local m = 0
  719.  
  720.         for i,v in pairs(tar:GetChildren()) do
  721.  
  722.                 if v:IsA("BasePart") then
  723.  
  724.                         m = m + v:GetMass()
  725.  
  726.                 end
  727.  
  728.                         m = m + gm(v)
  729.  
  730.         end
  731.  
  732.         return m
  733.  
  734. end
  735.  
  736. reqrotx = 0
  737.  
  738. local grav = 196.2
  739.  
  740. local con
  741.  
  742. con = game:GetService("RunService").Stepped:connect(oc(function()
  743.  
  744.         --[[if not mod:IsDescendantOf(workspace) then
  745.  
  746.                 pcall(function() kd:disconnect() end)
  747.  
  748.                 pcall(function() ku:disconnect() end)
  749.  
  750.                 bg:Destroy()
  751.  
  752.                 bv:Destroy()
  753.  
  754.                 con:disconnect()
  755.  
  756.                 script:Destroy()
  757.  
  758.                 return
  759.  
  760.         end]]
  761.  
  762.         local obvel = tor.CFrame:vectorToObjectSpace(tor.Velocity)
  763.  
  764.         local sspd, uspd,fspd = obvel.X,obvel.Y,obvel.Z
  765.  
  766.         if flying then
  767.  
  768.                 local lfldir = fldir
  769.  
  770.                 fldir = cam.CoordinateFrame:vectorToWorldSpace(Vector3.new(bn(keysdown.d)-bn(keysdown.a),0,bn(keysdown.s)-bn(keysdown.w))).unit
  771.  
  772.                 local lmoving = moving
  773.  
  774.                 moving = fldir.magnitude > .1
  775.  
  776.                 if lmoving and not moving then
  777.  
  778.                         idledir = lfldir*Vector3.new(1,0,1)
  779.  
  780.                         descendtimer = tick()
  781.  
  782.                 end
  783.  
  784.                 local dbomb = fldir.Y < -.6 or (moving and keysdown["1"])
  785.  
  786.                 if moving and keysdown["0"] and lmoving then
  787.  
  788.                         fldir = (Vector3.new(lfldir.X,math.min(fldir.Y,lfldir.Y+.01)-.1,lfldir.Z)+(fldir*Vector3.new(1,0,1))*.05).unit
  789.  
  790.                 end
  791.  
  792.                 local down = tor.CFrame:vectorToWorldSpace(Vector3.new(0,-1,0))
  793.  
  794.                 local descending = (not moving and keysdown["q"] and not keysdown[" "])
  795.  
  796.                 cf = ccomplerp(cf,CFrame.new(tor.Position,tor.Position+(not moving and idledir or fldir)),keysdown["0"] and .02 or .07)
  797.  
  798.                 local gdown = not dbomb and cf.lookVector.Y < -.2 and tor.Velocity.unit.Y < .05
  799.  
  800.                 hum.PlatformStand = true
  801.  
  802.                 bg.maxTorque = Vector3.new(1,1,1)*9e5
  803.  
  804.                 local rotvel = CFrame.new(Vector3.new(),tor.Velocity):toObjectSpace(CFrame.new(Vector3.new(),fldir)).lookVector
  805.  
  806.                 bg.cframe = cf * CFrame.Angles(not moving and -.1 or -math.pi/2+.2,moving and mid(-2.5,rotvel.X/1.5) + reqrotx or 0,0)
  807.  
  808.                 reqrotx = reqrotx - reqrotx/10
  809.  
  810.                 bv.maxForce = Vector3.new(1,1,1)*9e4*.5
  811.  
  812.                 local anioff =(bn(keysdown[" "])-bn(keysdown["q"]))/2
  813.  
  814.                 local ani = tickwave(1.5-anioff,1)
  815.  
  816.                 bv.velocity = bv.velocity:Lerp(Vector3.new(0,bn(not moving)*-ani*15+(descending and math.min(20,tick()-descendtimer)*-8 or bn(keysdown[" "])-bn(keysdown["q"]))*15,0)+vel,.6)
  817.  
  818.                 vel = moving and cf.lookVector*flspd or Vector3.new()
  819.  
  820.                 flspd = math.min(120,lerp(flspd,moving and (fldir.Y<0 and flspd+(-fldir.Y)*grav/60 or math.max(50,flspd-fldir.Y*grav/300)) or 60,.4))
  821.  
  822.                 setwings(moving and (gdown and outlow or dbomb and divebomb) or (descending and veryhigh or flap1),15)
  823.  
  824.                 for i=1,4 do
  825.  
  826.                         --CFrame.Angles(-.5+bn(i==3)*2.4+bn(i==4)*.5,.1+bn(i==2)*.5-bn(i==3)*1.1,bn(i==3)*.1)
  827.  
  828.                         rwing[i].C0 = clerp(rwing[i].C0,oc0[rwing[i]] * (gdown and CFrame.new() or dbomb and CFrame.Angles(-.5+bn(i==3)*.4+bn(i==4)*.5,.1+bn(i==2)*.5-bn(i==3)*1.1,bn(i==3)*.1) or descending and CFrame.Angles(.3,0,0) or CFrame.Angles((i*.1+1.5)*ani,ani*-.5,1*ani)),descending and .8 or .2)
  829.  
  830.                         lwing[i].C0 = clerp(lwing[i].C0,oc0[lwing[i]] * (gdown and CFrame.new() or dbomb and CFrame.Angles(-(-.5+bn(i==3)*.4+bn(i==4)*.5),-(.1+bn(i==2)*.5-bn(i==3)*1.1),bn(i==3)*.1) or descending and CFrame.Angles(-.3,0,0) or CFrame.Angles(-(i*.1+1.5)*ani,ani*.5,1*ani)),descending and .8 or .2)
  831.  
  832.                 end
  833.  
  834.                 local hit,ray = workspace:FindPartOnRayWithIgnoreList(Ray.new(tor.Position,Vector3.new(0,-3.5+math.min(0,bv.velocity.y)/30,0)),{char})
  835.  
  836.                 if hit and down.Y < -.85 and tick()-flystart > 1 then
  837.  
  838.                         flying = false
  839.  
  840.                         hum.PlatformStand = false
  841.  
  842.                         tor.Velocity = Vector3.new()
  843.  
  844.                 end
  845.  
  846.         else
  847.  
  848.                 bg.maxTorque = Vector3.new()
  849.  
  850.                 bv.maxForce = Vector3.new()
  851.  
  852.                 local ani = tickwave(walking and .8 or 4.5,1)
  853.  
  854.                 setwings(idle,10)
  855.  
  856.                 local x,y,z = fspd/160,uspd/700,sspd/900
  857.  
  858.                 for i=1,4 do
  859.  
  860.                         rwing[i].C0 = clerp(rwing[i].C0,oc0[rwing[i]] * CFrame.Angles(ani*.1 + -mid(-.1,x),0 + -mid(-.1,y) + bn(i==2)*.6,ani*.02 + -mid(-.1,z)),.2)
  861.  
  862.                         lwing[i].C0 = clerp(lwing[i].C0,oc0[lwing[i]] * CFrame.Angles(ani*-.05 + mid(-.1,x),0 + mid(-.1,y) + -bn(i==2)*.6,ani*.02 + mid(-.1,z)),.2)
  863.  
  864.                 end
  865.  
  866.                 if keypressed[" "] and not flying and (tick()-jumptime > .05 and (tick()-jumptime < 3 or hum.Jump)) then
  867.  
  868.                         vel = Vector3.new(0,50,0)
  869.  
  870.                         bv.velocity = vel
  871.  
  872.                         idledir = cam.CoordinateFrame.lookVector*Vector3.new(1,0,1)
  873.  
  874.                         cf = tor.CFrame * CFrame.Angles(-.01,0,0)
  875.  
  876.                         tor.CFrame = cf
  877.  
  878.                         bg.cframe = cf
  879.  
  880.                         flystart = tick()
  881.  
  882.                         flying = true
  883.  
  884.                 end
  885.  
  886.         end
  887.  
  888.         keypressed = {}
  889.  
  890. end))
  891.  
  892.  
  893.  
  894. end fly()
  895.  
  896. --Bird Wings By Rosemarijohn2
  897.  
  898. --// System Controls --\\
  899. function Debounces:New(name,cooldown)
  900.     local aaaaa = {Usable=true,Cooldown=cooldown or 2,CoolingDown=false,LastUse=0}
  901.     setmetatable(aaaaa,{__index = Debounces})
  902.     Debounces.Debounces[name] = aaaaa
  903.     return aaaaa
  904. end
  905.  
  906. function Debounces:Use(overrideUsable)
  907.     assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use")
  908.     if(self.Usable or overrideUsable)then
  909.         self.Usable = false
  910.         self.CoolingDown = true
  911.         local LastUse = time()
  912.         self.LastUse = LastUse
  913.         delay(self.Cooldown or 2,function()
  914.             if(self.LastUse == LastUse)then
  915.                 self.CoolingDown = false
  916.                 self.Usable = true
  917.             end
  918.         end)
  919.     end
  920. end
  921.  
  922. function Debounces:Get(name)
  923.     assert(typeof(name) == 'string',("bad argument #1 to 'get' (string expected, got %s)"):format(typeof(name) == nil and "no value" or typeof(name)))
  924.   for i,v in next, Debounces.Debounces do
  925.         if(i == name)then
  926.             return v;
  927.         end
  928.     end
  929. end
  930.  
  931. function Debounces:GetProgressPercentage()
  932.     assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use")
  933.     if(self.CoolingDown and not self.Usable)then
  934.         return math.max(
  935.             math.floor(
  936.                 (
  937.                     (time()-self.LastUse)/self.Cooldown or 2
  938.                 )*100
  939.             )
  940.         )
  941.     else
  942.         return 100
  943.     end
  944. end
  945.  
  946. --// Shortcut Variables \\--
  947. local CF = {N=CFrame.new,A=CFrame.Angles,fEA=CFrame.fromEulerAnglesXYZ}
  948. local C3 = {N=Color3.new,RGB=Color3.fromRGB,HSV=Color3.fromHSV,tHSV=Color3.toHSV}
  949. local V3 = {N=Vector3.new,FNI=Vector3.FromNormalId,A=Vector3.FromAxis}
  950. 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}
  951. local R3 = {N=Region3.new}
  952. local De = S.Debris
  953. local WS = workspace
  954. local Lght = S.Lighting
  955. local RepS = S.ReplicatedStorage
  956. local IN = Instance.new
  957. local CSK = ColorSequenceKeypoint.new
  958. local CS = ColorSequence.new
  959. --// Instance Creation Functions \\--
  960.  
  961. function Sound(parent,id,pitch,volume,looped,effect,autoPlay)
  962.     local Sound = IN("Sound")
  963.     Sound.SoundId = "rbxassetid://".. tostring(id or 0)
  964.     Sound.Pitch = pitch or 1
  965.     Sound.Volume = volume or 1
  966.     Sound.Looped = looped or false
  967.     if(autoPlay)then
  968.         coroutine.wrap(function()
  969.             repeat wait() until Sound.IsLoaded
  970.             Sound.Playing = autoPlay or false
  971.         end)()
  972.     end
  973.     if(not looped and effect)then
  974.         Sound.Stopped:connect(function()
  975.             Sound.Volume = 0
  976.             Sound:destroy()
  977.         end)
  978.     elseif(effect)then
  979.         warn("Sound can't be looped and a sound effect!")
  980.     end
  981.     Sound.Parent =parent or Torso
  982.     return Sound
  983. end
  984. function Part(parent,color,material,size,cframe,anchored,cancollide)
  985.     local part = IN("Part")
  986.     part[typeof(color) == 'BrickColor' and 'BrickColor' or 'Color'] = color or C3.N(0,0,0)
  987.   part.Material = (material or Enum.Material.SmoothPlastic)
  988.     part.TopSurface,part.BottomSurface=10,10
  989.     part.Size = (size or V3.N(1,1,1))
  990.     part.CFrame = (cframe or CF.N(0,0,0))
  991.     part.Anchored = (anchored or false)
  992.     part.CanCollide = (cancollide or false)
  993.     part.Parent = (parent or Char)
  994.     return part
  995. end
  996. function Mesh(parent,meshtype,meshid,textid,scale,offset)
  997.     local part = IN("SpecialMesh")
  998.     part.MeshId = meshid or ""
  999.     part.TextureId = textid or ""
  1000.     part.Scale = scale or V3.N(1,1,1)
  1001.     part.Offset = offset or V3.N(0,0,0)
  1002.     part.MeshType = meshtype or Enum.MeshType.Sphere
  1003.     part.Parent = parent
  1004.     return part
  1005. end
  1006.  
  1007. NewInstance = function(instance,parent,properties)
  1008.     local inst = Instance.new(instance,parent)
  1009.     if(properties)then
  1010.         for i,v in next, properties do
  1011.             pcall(function() inst[i] = v end)
  1012.         end
  1013.     end
  1014.     return inst;
  1015. end
  1016.  
  1017.  
  1018.  
  1019. --// Extended ROBLOX tables \\--
  1020. 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})
  1021. --// Customization \\--
  1022.  
  1023. local Frame_Speed = 60 -- The frame speed for swait. 1 is automatically divided by this
  1024. local Remove_Hats = false
  1025. local Remove_Clothing = true
  1026. local PlayerSize = 1
  1027. local DamageColor = BrickColor.new'Really red'
  1028. local MusicID = 379523580
  1029. local WalkSpeed = 8
  1030. local MaxSouls = 100
  1031. local MaxHealth = 500
  1032.  
  1033.  
  1034. if(_G.RefusedAnimation == nil) then _G.RefusedAnimation = false end
  1035.  
  1036. --// Weapon and GUI creation, and Character Customization \\--
  1037.  
  1038. if(Remove_Hats)then Instance.ClearChildrenOfClass(Char,"Accessory",true) end
  1039. if(Remove_Clothing)then Instance.ClearChildrenOfClass(Char,"Clothing",true) Instance.ClearChildrenOfClass(Char,"ShirtGraphic",true) end
  1040. local Effects = IN("Folder",Char)
  1041. Effects.Name = "Effects"
  1042.  
  1043. Hum.MaxHealth = MaxHealth
  1044. Hum.Health = MaxHealth
  1045.  
  1046. local Knife = NewInstance("Part",Char,{Name='Knife',Size=V3.N(.4,3,.7),Anchored=false,CanCollide=false,Locked=true,Archivable=false,Reflectance=.01,Color=C3.N(0,0,0)})
  1047. local KnifeMesh = Mesh(Knife,Enum.MeshType.FileMesh,"rbxassetid://121944778","rbxassetid://362719969",V3.N(1,1,1),V3.N())
  1048. local AuraEmitter = NewInstance("ParticleEmitter",Knife,{EmissionDirection='Back',Color=CS{CSK(0,C3.N(1,0,0)),CSK(0.5,C3.N(1,1,0)),CSK(1,C3.RGB(255,191,0))},LightEmission=.5,LightInfluence=0,Size=NumberSequence.new(0.3),Texture="rbxassetid://141116476",Transparency=NumberSequence.new(0,1),LockedToPart=true,Lifetime=NumberRange.new(1),Rate=150,Speed=NumberRange.new(0)})
  1049. local FireEmitter = NewInstance("ParticleEmitter",Knife,{EmissionDirection='Back',Color=CS(C3.N(1,0,0),C3.N(1,0,0)),LightEmission=.5,LightInfluence=0,Size=NumberSequence.new{NumberSequenceKeypoint.new(0,.5,0),NumberSequenceKeypoint.new(0.755,0,0),NumberSequenceKeypoint.new(1,0,0)},Texture="rbxassetid://141116476",Transparency=NumberSequence.new(0.35,1),Lifetime=NumberRange.new(1,2),Rate=150,Speed=NumberRange.new(3)})
  1050.  
  1051. local KTrail = NewInstance("Trail",Knife,{
  1052.     Attachment0=NewInstance("Attachment",Knife,{Position=V3.N(0,-.4,0)}),
  1053.     Attachment1=NewInstance("Attachment",Knife,{Position=V3.N(0,1.2,0)}),
  1054.     Color=CS(C3.N(1,0,0)),
  1055.     Enabled=false,
  1056.     Transparency=NumberSequence.new(0,1),
  1057.     Lifetime=1.25,
  1058. })
  1059. local Hair = Part(Char,C3.N(0,0,0),Enum.Material.SmoothPlastic,V3.N(1,1,1),CF.N(),false,false)
  1060. local HairMesh = Mesh(Hair,Enum.MeshType.FileMesh,"rbxassetid://250264520","rbxassetid://75975464",V3.N(1.05,1.05,1.05),V3.N())
  1061.  
  1062. NewInstance("PointLight",Knife,{Color=C3.N(1,0,0),Range=10,Brightness=3})
  1063.  
  1064.  
  1065. Hum.DisplayDistanceType = 'None'
  1066.  
  1067. local naeeym2 = IN("BillboardGui",Char)
  1068. naeeym2.AlwaysOnTop = true
  1069. naeeym2.Size = UDim2.new(5,35,2,15)
  1070. naeeym2.StudsOffset = V3.N(0,2.5,0)
  1071. naeeym2.Adornee = Char.Head
  1072. naeeym2.Name = "Name"
  1073. naeeym2.PlayerToHideFrom = Plr
  1074. local tecks2 = IN("TextLabel",naeeym2)
  1075. tecks2.BackgroundTransparency = 1
  1076. tecks2.TextScaled = true
  1077. tecks2.BorderSizePixel = 0
  1078. tecks2.Text = "Glitch Tale Chara"
  1079. tecks2.Font = Enum.Font.Bodoni
  1080. tecks2.TextSize = 30
  1081. tecks2.TextStrokeTransparency = 0
  1082. tecks2.TextColor3 = C3.N(0,0,0)
  1083. tecks2.TextStrokeColor3 = C3.N(.7,0,0)
  1084. tecks2.Size = UDim2.new(1,0,0.5,0)
  1085. tecks2.Parent = naeeym2
  1086.  
  1087.  
  1088. IN("Shirt",Char)
  1089. IN("Pants",Char)
  1090.  
  1091. Hum.WalkSpeed = WalkSpeed
  1092. if(PlayerSize ~= 1)then
  1093.     for _,v in next, Char:GetDescendats() do
  1094.         if(v:IsA'BasePart')then
  1095.           v.Size = v.Size * PlayerSize
  1096.         end
  1097.     end
  1098. end
  1099.  
  1100.  
  1101. for i = 1, 35 do
  1102.     local FACE = Part(Char,C3.N(0,0,0),Enum.Material.Neon,V3.N(1.01,.5,1.01),CF.N(),false,false)
  1103.     FACE.Transparency = 0+(i-1)/35.2
  1104.     FACE.Name = 'ShadowFace'
  1105.   Head:FindFirstChildOfClass("SpecialMesh"):Clone().Parent = FACE
  1106.     NewInstance("Weld",Head,{Part0=Head,Part1=FACE,C0=CF.N(0,.35-(i-1)/75,0)})
  1107.     --CreateWeldOrSnapOrMotor("Weld", Head, Head, FACE, CF(0,0.35-(i-1)/75,0), CF(0, 0, 0))
  1108. end
  1109.  
  1110. local LEye = Part(Char,C3.N(1,0,0),Enum.Material.Neon,V3.N(.15,.25,.2),CF.N(),false,false)
  1111. local LEyeM = Mesh(LEye,Enum.MeshType.Sphere,"","",V3.N(1,1,1),V3.N())
  1112. local LEyeW = NewInstance("Weld",LEye,{Part0=Head,Part1=LEye,C0=CF.N(-.2,.2,-.49)})
  1113.  
  1114. local REye = Part(Char,C3.N(1,0,0),Enum.Material.Neon,V3.N(.15,.25,.2),CF.N(),false,false)
  1115. local REyeM = Mesh(REye,Enum.MeshType.Sphere,"","",V3.N(1,1,1),V3.N())
  1116. local REyeW = NewInstance("Weld",REye,{Part0=Head,Part1=REye,C0=CF.N(.2,.2,-.49)})
  1117.  
  1118.  
  1119. pcall(function()
  1120.     Char.LeftWing:destroy()
  1121.     Char.ReaperShadowHead:destroy()
  1122. end)
  1123.  
  1124.  
  1125. local Music = Sound(Torso,MusicID,1,3,true,false,true)
  1126. Music.Name = 'Music'
  1127.  
  1128. --// Stop animations \\--
  1129. for _,v in next, Hum:GetPlayingAnimationTracks() do
  1130.     v:Stop();
  1131. end
  1132.  
  1133. pcall(game.Destroy,Char:FindFirstChild'Animate')
  1134. pcall(game.Destroy,Hum:FindFirstChild'Animator')
  1135.  
  1136. --// Joints \\--
  1137.  
  1138. 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)})
  1139. 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)})
  1140. local NK = NewInstance('Motor',Char,{Part0=Torso,Part1=Head,C0 = CF.N(0,1.5 * PlayerSize,0)})
  1141. local LH = NewInstance('Motor',Char,{Part0=Torso,Part1=LLeg,C0 = CF.N(-.5 * PlayerSize,-1 * PlayerSize,0),C1 = CF.N(0,1 * PlayerSize,0)})
  1142. local RH = NewInstance('Motor',Char,{Part0=Torso,Part1=RLeg,C0 = CF.N(.5 * PlayerSize,-1 * PlayerSize,0),C1 = CF.N(0,1 * PlayerSize,0)})
  1143. local RJ = NewInstance('Motor',Char,{Part0=Root,Part1=Torso})
  1144. local HW = NewInstance('Motor',Char,{Part0=RArm,Part1=Knife,C0=CF.N(0,-1,-1)*CF.A(M.R(-90),0,0)})
  1145. local HW2 = NewInstance('Motor',Char,{Part0=Head,Part1=Hair,C0=CF.N(0,.25,0)})
  1146.  
  1147. local LSC0 = LS.C0
  1148. local RSC0 = RS.C0
  1149. local NKC0 = NK.C0
  1150. local LHC0 = LH.C0
  1151. local RHC0 = RH.C0
  1152. local RJC0 = RJ.C0
  1153.  
  1154. --// Artificial HB \\--
  1155.  
  1156. local ArtificialHB = IN("BindableEvent", script)
  1157. ArtificialHB.Name = "Heartbeat"
  1158.  
  1159. script:WaitForChild("Heartbeat")
  1160.  
  1161. local tf = 0
  1162. local allowframeloss = false
  1163. local tossremainder = false
  1164. local lastframe = tick()
  1165. local frame = 1/Frame_Speed
  1166. ArtificialHB:Fire()
  1167.  
  1168. game:GetService("RunService").Heartbeat:connect(function(s, p)
  1169.     tf = tf + s
  1170.     if tf >= frame then
  1171.         if allowframeloss then
  1172.             script.Heartbeat:Fire()
  1173.             lastframe = tick()
  1174.         else
  1175.             for i = 1, math.floor(tf / frame) do
  1176.                 ArtificialHB:Fire()
  1177.             end
  1178.             lastframe = tick()
  1179.         end
  1180.         if tossremainder then
  1181.             tf = 0
  1182.         else
  1183.             tf = tf - frame * math.floor(tf / frame)
  1184.         end
  1185.     end
  1186. end)
  1187.  
  1188. function swait(num)
  1189.     if num == 0 or num == nil then
  1190.         ArtificialHB.Event:wait()
  1191.     else
  1192.         for i = 0, num do
  1193.             ArtificialHB.Event:wait()
  1194.         end
  1195.     end
  1196. end
  1197.  
  1198.  
  1199. --// Effect Function(s) \\--
  1200.  
  1201. function Bezier(startpos, pos2, pos3, endpos, t)
  1202.     local A = startpos:lerp(pos2, t)
  1203.     local B  = pos2:lerp(pos3, t)
  1204.     local C = pos3:lerp(endpos, t)
  1205.     local lerp1 = A:lerp(B, t)
  1206.     local lerp2 = B:lerp(C, t)
  1207.     local cubic = lerp1:lerp(lerp2, t)
  1208.     return cubic
  1209. end
  1210.  
  1211. function Tween(obj,props,time,easing,direction,repeats,backwards)
  1212.     local info = TweenInfo.new(time or .5, easing or Enum.EasingStyle.Quad, direction or Enum.EasingDirection.Out, repeats or 0, backwards or false)
  1213.     local tween = S.TweenService:Create(obj, info, props)
  1214.    
  1215.     tween:Play()
  1216. end
  1217.  
  1218. local FXTable = {}
  1219.  
  1220. coroutine.resume(coroutine.create(function()
  1221.     while true do
  1222.         for i = 1, #FXTable do
  1223.             local data = FXTable[i]
  1224.             if(data)then
  1225.                 local Frame = data.Frame
  1226.                 local FX = data.Effect or 'ResizeAndFade'
  1227.               local Parent = data.Parent or Effects
  1228.                 local Color = data.Color or C3.N(0,0,0)
  1229.                 local Size = data.Size or V3.N(1,1,1)
  1230.                 local MoveDir = data.MoveDirection or nil
  1231.                 local MeshData = data.Mesh or nil
  1232.                 local SndData = data.Sound or nil
  1233.                 local Frames = data.Frames or 45
  1234.                 local CFra = data.CFrame or Torso.CFrame
  1235.                 local Settings = data.FXSettings or {}
  1236.                 local Prt,Msh,Snd = data.Part,data.Mesh,data.Sound
  1237.                 local grow = data.Grow
  1238.                
  1239.                 local MoveSpeed = nil;
  1240.                 if(MoveDir)then
  1241.                     MoveSpeed = (CFra.p - MoveDir).magnitude/Frames
  1242.                 end
  1243.                 if(FX ~= 'Arc')then
  1244.                   Frame = Frame + 1
  1245.                     if(FX == "Fade")then
  1246.                         Prt.Transparency  = (Frame/Frames)
  1247.                     elseif(FX == "Resize")then
  1248.                         if(not Settings.EndSize)then
  1249.                             Settings.EndSize = V3.N(0,0,0)
  1250.                         end
  1251.                         if(Settings.EndIsIncrement)then
  1252.                             if(Msh)then
  1253.                                 Msh.Scale = Msh.Scale + Settings.EndSize
  1254.                             else
  1255.                                 Prt.Size = Prt.Size + Settings.EndSize
  1256.                             end                
  1257.                         else
  1258.                             if(Msh)then
  1259.                                 Msh.Scale = Msh.Scale - grow/Frames
  1260.                             else
  1261.                                 Prt.Size = Prt.Size - grow/Frames
  1262.                             end
  1263.                         end
  1264.                     elseif(FX == "ResizeAndFade")then
  1265.                         if(not Settings.EndSize)then
  1266.                             Settings.EndSize = V3.N(0,0,0)
  1267.                         end
  1268.                         if(Settings.EndIsIncrement)then
  1269.                             if(Msh)then
  1270.                                 Msh.Scale = Msh.Scale + Settings.EndSize
  1271.                             else
  1272.                                 Prt.Size = Prt.Size + Settings.EndSize
  1273.                             end                
  1274.                         else
  1275.                             if(Msh)then
  1276.                                 Msh.Scale = Msh.Scale - grow/Frames
  1277.                             else
  1278.                                 Prt.Size = Prt.Size - grow/Frames
  1279.                             end
  1280.                         end
  1281.                         Prt.Transparency = (Frame/Frames)
  1282.                     end
  1283.                     if(Settings.RandomizeCFrame)then
  1284.                         Prt.CFrame = Prt.CFrame * CF.A(M.RRNG(-360,360),M.RRNG(-360,360),M.RRNG(-360,360))
  1285.                     end
  1286.                     if(MoveDir and MoveSpeed)then
  1287.                         local Orientation = Prt.Orientation
  1288.                         Prt.CFrame = CF.N(Prt.Position,MoveDir)*CF.N(0,0,-MoveSpeed)
  1289.                         Prt.Orientation = Orientation
  1290.                     end
  1291.                     if(Prt.Transparency >= 1 or Frame >= Frames)then
  1292.                         Prt:destroy()
  1293.                         table.remove(FXTable,i)
  1294.                     else
  1295.                         data.Frame = Frame
  1296.                     end
  1297.                 else
  1298.                     local start,third,fourth,endP = Settings.Start,Settings.Third,Settings.Fourth,Settings.End
  1299.                     if(not Settings.End and Settings.Home)then endP = Settings.Home.CFrame end
  1300.                     if(start and endP)then
  1301.                         local quarter = third or start:lerp(endP, 0.25) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
  1302.                         local threequarter = fourth or start:lerp(endP, 0.75) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
  1303.                         Frame = Frame + (Settings.Speed or 0.01)
  1304.                         if(Settings.Home)then
  1305.                             endP = Settings.Home.CFrame
  1306.                         end
  1307.                         Prt.CFrame = Bezier(start, quarter, threequarter, endP, Frame)
  1308.                         if(Prt.Transparency >= 1 or Frame >= Frames)then
  1309.                             if(Settings.RemoveOnGoal)then
  1310.                                 Prt:destroy()
  1311.                             end
  1312.                         end
  1313.                     else
  1314.                         Prt:destroy()
  1315.                     end
  1316.                 end
  1317.             end
  1318.         end
  1319.         swait()
  1320.     end
  1321. end))
  1322.  
  1323. function Effect(data)
  1324.     local FX = data.Effect or 'ResizeAndFade'
  1325.   local Parent = data.Parent or Effects
  1326.     local Color = data.Color or C3.N(0,0,0)
  1327.     local Size = data.Size or V3.N(1,1,1)
  1328.     local MoveDir = data.MoveDirection or nil
  1329.     local MeshData = data.Mesh or nil
  1330.     local SndData = data.Sound or nil
  1331.     local Frames = data.Frames or 45
  1332.     local Manual = data.Manual or nil
  1333.     local Material = data.Material or nil
  1334.     local CFra = data.CFrame or Torso.CFrame
  1335.     local Settings = data.FXSettings or {}
  1336.     local Shape = data.Shape or Enum.PartType.Block
  1337.     local Snd,Prt,Msh;
  1338.     coroutine.wrap(function()
  1339.         if(Manual and typeof(Manual) == 'Instance' and Manual:IsA'BasePart')then
  1340.           Prt = Manual
  1341.         else
  1342.             Prt = Part(Parent,Color,Material,Size,CFra,true,false)
  1343.             Prt.Shape = Shape
  1344.         end
  1345.         if(typeof(MeshData) == 'table')then
  1346.           Msh = Mesh(Prt,MeshData.MeshType,MeshData.MeshId,MeshData.TextureId,MeshData.Scale,MeshData.Offset)
  1347.         elseif(typeof(MeshData) == 'Instance')then
  1348.           Msh = MeshData:Clone()
  1349.             Msh.Parent = Prt
  1350.         elseif(Shape == Enum.PartType.Block)then
  1351.             Msh = Mesh(Prt,Enum.MeshType.Brick)
  1352.         end
  1353.         if(typeof(SndData) == 'table' or typeof(SndData) == 'Instance')then
  1354.           Snd = Sound(Prt,SndData.SoundId,SndData.Pitch,SndData.Volume,false,false,true)
  1355.         end
  1356.         if(Snd)then
  1357.             repeat swait() until Snd.Playing and Snd.IsLoaded and Snd.TimeLength > 0
  1358.             Frames = Snd.TimeLength * Frame_Speed/Snd.Pitch
  1359.         end
  1360.         Size = (Msh and Msh.Scale or Size)
  1361.         local grow = Size-(Settings.EndSize or (Msh and Msh.Scale or Size)/2)
  1362.        
  1363.         local MoveSpeed = nil;
  1364.         if(MoveDir)then
  1365.             MoveSpeed = (CFra.p - MoveDir).magnitude/Frames
  1366.         end
  1367.         if(FX ~= 'Arc')then
  1368.           for Frame = 1, Frames do
  1369.                 if(FX == "Fade")then
  1370.                     Prt.Transparency  = (Frame/Frames)
  1371.                 elseif(FX == "Resize")then
  1372.                     if(not Settings.EndSize)then
  1373.                         Settings.EndSize = V3.N(0,0,0)
  1374.                     end
  1375.                     if(Settings.EndIsIncrement)then
  1376.                         if(Msh)then
  1377.                             Msh.Scale = Msh.Scale + Settings.EndSize
  1378.                         else
  1379.                             Prt.Size = Prt.Size + Settings.EndSize
  1380.                         end                
  1381.                     else
  1382.                         if(Msh)then
  1383.                             Msh.Scale = Msh.Scale - grow/Frames
  1384.                         else
  1385.                             Prt.Size = Prt.Size - grow/Frames
  1386.                         end
  1387.                     end
  1388.                 elseif(FX == "ResizeAndFade")then
  1389.                     if(not Settings.EndSize)then
  1390.                         Settings.EndSize = V3.N(0,0,0)
  1391.                     end
  1392.                     if(Settings.EndIsIncrement)then
  1393.                         if(Msh)then
  1394.                             Msh.Scale = Msh.Scale + Settings.EndSize
  1395.                         else
  1396.                             Prt.Size = Prt.Size + Settings.EndSize
  1397.                         end                
  1398.                     else
  1399.                         if(Msh)then
  1400.                             Msh.Scale = Msh.Scale - grow/Frames
  1401.                         else
  1402.                             Prt.Size = Prt.Size - grow/Frames
  1403.                         end
  1404.                     end
  1405.                     Prt.Transparency = (Frame/Frames)
  1406.                 end
  1407.                 if(Settings.RandomizeCFrame)then
  1408.                     Prt.CFrame = Prt.CFrame * CF.A(M.RRNG(-360,360),M.RRNG(-360,360),M.RRNG(-360,360))
  1409.                 end
  1410.                 if(MoveDir and MoveSpeed)then
  1411.                     local Orientation = Prt.Orientation
  1412.                     Prt.CFrame = CF.N(Prt.Position,MoveDir)*CF.N(0,0,-MoveSpeed)
  1413.                     Prt.Orientation = Orientation
  1414.                 end
  1415.                 swait()
  1416.             end
  1417.             Prt:destroy()
  1418.         else
  1419.             local start,third,fourth,endP = Settings.Start,Settings.Third,Settings.Fourth,Settings.End
  1420.             if(not Settings.End and Settings.Home)then endP = Settings.Home.CFrame end
  1421.             if(start and endP)then
  1422.                 local quarter = third or start:lerp(endP, 0.25) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
  1423.                 local threequarter = fourth or start:lerp(endP, 0.75) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
  1424.                 for Frame = 0, 1, (Settings.Speed or 0.01) do
  1425.                     if(Settings.Home)then
  1426.                         endP = Settings.Home.CFrame
  1427.                     end
  1428.                     Prt.CFrame = Bezier(start, quarter, threequarter, endP, Frame)
  1429.                 end
  1430.                 if(Settings.RemoveOnGoal)then
  1431.                     Prt:destroy()
  1432.                 end
  1433.             else
  1434.                 Prt:destroy()
  1435.                 assert(start,"You need a start position!")
  1436.                 assert(endP,"You need a start position!")
  1437.             end
  1438.         end
  1439.     end)()
  1440.     return Prt,Msh,Snd
  1441. end
  1442.  
  1443.  
  1444.  
  1445. function SoulSteal(whom,human)
  1446.     local torso = (whom:FindFirstChild'Torso' or whom:FindFirstChild'UpperTorso' or whom:FindFirstChild'LowerTorso' or whom:FindFirstChild'HumanoidRootPart' or whom:FindFirstChild'Torso')
  1447.   local succ, health, alive = pcall(function() return whom:FindFirstChildOfClass'Humanoid'.Health, whom:FindFirstChildOfClass'Humanoid'.Health > 0 end)
  1448.   if(torso and torso:IsA'BasePart' and alive == true)then
  1449.       whom:FindFirstChildOfClass'Humanoid'.Health = 0
  1450.       whom:BreakJoints()
  1451.         local Model = IN("Model",Effects)
  1452.         warn('Soul stolen from '..whom.Name)
  1453.       Model.Name = whom.Name.."'s Soul"
  1454.         local Soul = Part(Model,(human and BrickColor.new'Really red' or BrickColor.new(C3.N(1,1,1))),'Glass',V3.N(1,1,1),torso.CFrame,true,false)
  1455.       Soul.CanCollide=false
  1456.         Mesh(Soul,Enum.MeshType.Sphere)
  1457.         Soul.Name = 'Head'
  1458.       if(whom.Name == 'CKbackup')then
  1459.           Soul.Color = C3.N(1,1,1)
  1460.             local DripEmitter = NewInstance("ParticleEmitter",Soul,{EmissionDirection='Bottom',Color=CS(Soul.Color),LightEmission=.5,LightInfluence=0,Size=NumberSequence.new(0.3),Texture="rbxassetid://243132757",Transparency=NumberSequence.new(0,1),LockedToPart=false,Lifetime=NumberRange.new(1),Rate=150,Speed=NumberRange.new(5)})
  1461.       end
  1462.         local Hoom = NewInstance("Humanoid",Model,{MaxHealth=(health <= 10000 and health/2 or 10000),Health=(health <= 10000 and health/2 or 10000)})
  1463.         local AT0 = NewInstance("Attachment",Soul,{Position=V3.N(0,.5,0)})
  1464.         local AT1 = NewInstance("Attachment",Soul,{Position=V3.N(0,-.5,0)})
  1465.         local Trail = NewInstance("Trail",Soul,{Attachment0=AT0,Attachment1=AT1,Transparency=NumberSequence.new(0),FaceCamera = true,Texture="rbxassetid://945758042",LightEmission=.3,Color=CS(Soul.Color),Lifetime=.5,MinLength=0})
  1466.         NewInstance("PointLight",Soul,{Color=Soul.Color,Range=10,Brightness=(human and 3 or .5)})
  1467.        
  1468.         local turdso = Soul:Clone()
  1469.         turdso.Name = "Torso"
  1470.         turdso.CanCollide = false
  1471.         turdso.Anchored = true
  1472.         turdso.CFrame = Soul.CFrame
  1473.         turdso.Parent = Model
  1474.         turdso.Size = V3.N()
  1475.         turdso.Transparency=1
  1476.         local Distance = math.huge
  1477.         repeat
  1478.             Soul.CFrame = CF.N(Soul.Position,Torso.Position)*CF.N(0,0,-1)
  1479.             turdso.CFrame = Soul.CFrame
  1480.             Distance = (Soul.CFrame.p-Torso.CFrame.p).magnitude
  1481.             swait()
  1482.         until Hoom.Health <= 0 or not Soul.Parent or Distance <= 1.2
  1483.         if(Soul.Parent and Hoom.Health > 0)then
  1484.             Model:destroy()
  1485.             Effect{
  1486.                 Effect="ResizeAndFade",
  1487.                 Mesh={Enum.MeshType.Sphere},
  1488.                 Color = Soul.Color,
  1489.                 CFrame=Torso.CFrame,
  1490.                 Size=V3.N(3,3,3),
  1491.                 Material=Enum.Material.Neon,
  1492.                 Sound={SoundId=444667859,Pitch=1,Volume=2.5},
  1493.                 FXSettings={
  1494.                     EndSize=V3.N(6,6,6),
  1495.                 }
  1496.             }
  1497.             Souls = Souls + (human and 1 or .1)
  1498.             warn("Souls: "..Souls)
  1499.             MaxHealth = MaxHealth + Hoom.Health
  1500.             Hum.Health = Hum.Health + Hoom.Health
  1501.             for i = 1, 5 do
  1502.                 Effect{
  1503.                     Effect="Fade",
  1504.                     Color = Soul.Color,
  1505.                     MoveDirection = (Torso.CFrame*CFrame.new(M.RNG(-40,40),M.RNG(-40,40),M.RNG(-40,40))).p
  1506.                 }  
  1507.             end
  1508.         else
  1509.            
  1510.             warn("Soul destroyed!")
  1511.             for i = 1, 5 do
  1512.                 Effect{
  1513.                     Effect="Fade",
  1514.                     Color = Soul.Color,
  1515.                     CFrame=Soul.CFrame,
  1516.                     MoveDirection = (Soul.CFrame*CFrame.new(M.RNG(-40,40),M.RNG(-40,40),M.RNG(-40,40))).p
  1517.                 }  
  1518.             end
  1519.             Effect{
  1520.                 Effect="ResizeAndFade",
  1521.                 Mesh={Enum.MeshType.Sphere},
  1522.                 Sound={SoundId=444667859,Pitch=1,Volume=5},
  1523.                 Color = Soul.Color,
  1524.                 CFrame=Soul.CFrame,
  1525.                 Size=V3.N(3,3,3),
  1526.                 Material=Enum.Material.Neon,
  1527.                 FXSettings={
  1528.                     EndSize=V3.N(6,6,6),
  1529.                 }
  1530.             }
  1531.             Model:destroy()
  1532.         end
  1533.     end
  1534. end
  1535.  
  1536. --// Other Functions \\ --
  1537.  
  1538. function getRegion(point,range,ignore)
  1539.     return workspace:FindPartsInRegion3WithIgnoreList(R3.N(point-V3.N(1,1,1)*range/2,point+V3.N(1,1,1)*range/2),ignore,100)
  1540. end
  1541.  
  1542. function clerp(startCF,endCF,alpha)
  1543.     return startCF:lerp(endCF, alpha)
  1544. end
  1545.  
  1546. function GetTorso(char)
  1547.     return char:FindFirstChild'Torso' or char:FindFirstChild'UpperTorso' or char:FindFirstChild'LowerTorso' or char:FindFirstChild'HumanoidRootPart'
  1548. end
  1549.  
  1550. function ShowDamage(Pos, Text, Time, Color)
  1551.     coroutine.wrap(function()
  1552.     local Rate = (1 / Frame_Speed)
  1553.     local Pos = (Pos or Vector3.new(0, 0, 0))
  1554.     local Text = (Text or "")
  1555.     local Time = (Time or 2)
  1556.     local Color = (Color or Color3.new(1, 0, 1))
  1557.     local EffectPart = NewInstance("Part",Effects,{
  1558.         Material=Enum.Material.SmoothPlastic,
  1559.         Reflectance = 0,
  1560.         Transparency = 1,
  1561.         BrickColor = BrickColor.new(Color),
  1562.         Name = "Effect",
  1563.         Size = Vector3.new(0,0,0),
  1564.         Anchored = true,
  1565.         CFrame = CF.N(Pos)
  1566.     })
  1567.     local BillboardGui = NewInstance("BillboardGui",EffectPart,{
  1568.         Size = UDim2.new(1.25, 0, 1.25, 0),
  1569.         Adornee = EffectPart,
  1570.     })
  1571.     local TextLabel = NewInstance("TextLabel",BillboardGui,{
  1572.         BackgroundTransparency = 1,
  1573.         Size = UDim2.new(1, 0, 1, 0),
  1574.         Text = Text,
  1575.         Font = "Arcade",
  1576.         TextColor3 = Color,
  1577.         TextStrokeColor3 = Color3.new(0,0,0),
  1578.         TextStrokeTransparency=0,
  1579.         TextScaled = true,
  1580.     })
  1581.     S.Debris:AddItem(EffectPart, (Time))
  1582.     EffectPart.Parent = workspace
  1583.     delay(0, function()
  1584.         Tween(EffectPart,{CFrame=CF.N(Pos)*CF.N(0,3,0)},Time,Enum.EasingStyle.Elastic,Enum.EasingDirection.Out)
  1585.         local Frames = (Time / Rate)
  1586.         for Frame = 1, Frames do
  1587.             swait()
  1588.             local Percent = (Frame / Frames)
  1589.             TextLabel.TextTransparency = Percent
  1590.             TextLabel.TextStrokeTransparency = Percent
  1591.         end
  1592.         if EffectPart and EffectPart.Parent then
  1593.             EffectPart:Destroy()
  1594.         end
  1595.     end) end)()
  1596. end
  1597.  
  1598. function Kill(whom)
  1599.     if(whom.Name ~= 'Nebula_Zorua')then
  1600.       local isPlr = Plrs:GetPlayerFromCharacter(whom) ~= nil
  1601.         coroutine.wrap(SoulSteal)(whom,isPlr)
  1602.         for _,v in next, whom:children() do
  1603.             if(v:IsA'BasePart')then
  1604.               v.Parent = Effects
  1605.                 v:ClearAllChildren()
  1606.                 v.Anchored = true
  1607.                 v.CanCollide = false
  1608.                 v.Transparency = 1
  1609.                 local dust = NewInstance("ParticleEmitter",v,{
  1610.                     Color = ColorSequence.new(C3.N(1,1,1)),
  1611.                     LightEmission=0,
  1612.                     LightInfluence=1,
  1613.                     Size=NumberSequence.new{NumberSequenceKeypoint.new(0,1,0),NumberSequenceKeypoint.new(1,0,0)},
  1614.                     Texture="rbxassetid://284205403",
  1615.                     Transparency=NumberSequence.new{NumberSequenceKeypoint.new(0,0,0),NumberSequenceKeypoint.new(1,1,0)},
  1616.                     Lifetime = NumberRange.new(1),
  1617.                     Rate=150,
  1618.                     Acceleration = V3.N(0,10,0),
  1619.                     Speed = NumberRange.new(5),
  1620.                     Enabled = true
  1621.                 })
  1622.                 delay(1, function()
  1623.                     dust.Enabled = false
  1624.                     S.Debris:AddItem(v,2)
  1625.                 end)
  1626.             end
  1627.         end
  1628.     else
  1629.         warn"nope. nawt happenin'"
  1630.     end
  1631. end
  1632.  
  1633. function DealDamage(who,minDam,maxDam,Knock,Type,critChance,critMult)
  1634.     if(who)then
  1635.         local hum = who:FindFirstChildOfClass'Humanoid'
  1636.       local Damage = M.RNG(minDam,maxDam)
  1637.         local canHit = true
  1638.         if(hum)then
  1639.             for _, p in pairs(Hit) do
  1640.                 if p[1] == hum then
  1641.                     if(time() - p[2] < 0.4) then
  1642.                         canHit = false
  1643.                     else
  1644.                         Hit[_] = nil
  1645.                     end
  1646.                 end
  1647.             end
  1648.             if(canHit)then
  1649.                 table.insert(Hit,{hum,time()})
  1650.                 if(GetTorso(who))then
  1651.                     Sound(GetTorso(who),406913243,1,10,false,true,true)
  1652.                 end
  1653.                 if(hum.Health >= math.huge)then
  1654.                     Kill(who)
  1655.                     if(who:FindFirstChild'Head' and hum.Health > 0)then
  1656.                       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", 3, DamageColor.Color)
  1657.                     end
  1658.                 else
  1659.                     local player = S.Players:GetPlayerFromCharacter(who)
  1660.                     if(Type == "Fire")then
  1661.                         --idk..
  1662.                     else
  1663.                         local  c = Instance.new("ObjectValue",hum)
  1664.                         c.Name = "creator"
  1665.                         c.Value = Plr
  1666.                         game:service'Debris':AddItem(c,0.35)
  1667.                       local Crit = false
  1668.                         if(M.RNG(1,100) <= (critChance or 0) and critMult > 1)then
  1669.                             Crit = true
  1670.                             Damage = Damage*(critMult or 2)
  1671.                         end
  1672.                         Damage = Damage*((Souls/5)+1)
  1673.                         if(who:FindFirstChild'Head' and hum.Health > 0)then
  1674.                           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 and "[CRIT] " or "").. math.floor(Damage), 3, (Crit and BrickColor.new'New Yeller'.Color or DamageColor.Color))
  1675.                       end
  1676.                        
  1677.                         if(hum.Health - Damage <= 0)then
  1678.                             Kill(who)
  1679.                         else
  1680.                             hum.Health = hum.Health - Damage
  1681.                             if(Type == 'Knockback' and GetTorso(who))then
  1682.                               local angle = GetTorso(who).Position - Root.Position + Vector3.new(0, 0, 0).unit
  1683.                                 local body = NewInstance('BodyVelocity',GetTorso(who),{
  1684.                                   P = 500,
  1685.                                     maxForce = V3.N(math.huge,0,math.huge),
  1686.                                     velocity = Root.CFrame.lookVector * Knock + Root.Velocity / 1.05
  1687.                                 })
  1688.                                 game:service'Debris':AddItem(body,.5)
  1689.                           elseif(Type == "Electric")then
  1690.                                 if(M.RNG(1,100) >= critChance)then
  1691.                                     if(who:FindFirstChild'Head' and hum.Health > 0)then
  1692.                                       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]", 3, BrickColor.new"New Yeller".Color)
  1693.                                     end
  1694.                                     local asd = hum.WalkSpeed/2
  1695.                                     hum.WalkSpeed = asd
  1696.                                     local paralyzed = true
  1697.                                     coroutine.wrap(function()
  1698.                                         while paralyzed do
  1699.                                             swait(25)
  1700.                                             if(M.RNG(1,25) == 1)then
  1701.                                                 if(who:FindFirstChild'Head' and hum.Health > 0)then
  1702.                                                   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]", 3, BrickColor.new"New Yeller".Color)
  1703.                                                 end
  1704.                                                 hum.PlatformStand = true
  1705.                                             end
  1706.                                         end
  1707.                                     end)()
  1708.                                     delay(4, function()
  1709.                                         paralyzed = false
  1710.                                         hum.WalkSpeed = hum.WalkSpeed + asd
  1711.                                     end)
  1712.                                 end
  1713.                                
  1714.                             elseif(Type == 'Knockdown' and GetTorso(who))then
  1715.                               local rek = GetTorso(who)
  1716.                                 hum.PlatformStand = true
  1717.                                 delay(1,function()
  1718.                                     hum.PlatformStand = false
  1719.                                 end)
  1720.                                 local angle = (GetTorso(who).Position - (Root.Position + Vector3.new(0, 0, 0))).unit
  1721.                                 local bodvol = NewInstance("BodyVelocity",rek,{
  1722.                                     velocity = angle * Knock,
  1723.                                     P = 5000,
  1724.                                     maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
  1725.                                 })
  1726.                                 local rl = NewInstance("BodyAngularVelocity",rek,{
  1727.                                     P = 3000,
  1728.                                     maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000,
  1729.                                     angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)),
  1730.                                 })
  1731.                                 game:GetService("Debris"):AddItem(bodvol, .5)
  1732.                                 game:GetService("Debris"):AddItem(rl, .5)
  1733.                             end
  1734.                         end
  1735.                     end
  1736.                 end
  1737.             end
  1738.         end
  1739.     end
  1740. end
  1741.  
  1742.  
  1743. function AOEDamage(where,range,minDam,maxDam,Knock,Type,critChance,critMult)
  1744.     for _,v in next, getRegion(where,range,{Char}) do
  1745.         if(v.Name ~= 'Nebula_Zorua')then
  1746.           if(v.Parent and v.Parent:FindFirstChildOfClass'Humanoid')then
  1747.               DealDamage(v.Parent,minDam,maxDam,Knock,Type,critChance,critMult)
  1748.             end
  1749.         end
  1750.     end
  1751. end
  1752.  
  1753. function AOEKill(where,range)
  1754.     for _,v in next, getRegion(where,range,{Char,Effects}) do
  1755.         local succ,alive = pcall(function() return v.Parent:FindFirstChildOfClass'Humanoid'.Health > 0 end)
  1756.       if(v.Name ~= 'Nebula_Zorua')then
  1757.           if(v.Parent and alive == true)then
  1758.                 coroutine.wrap(Kill)(v.Parent)
  1759.             end
  1760.         end
  1761.     end
  1762. end
  1763.  
  1764. function AOEHeal(where,range,amount)
  1765.     local healed = {}
  1766.     for _,v in next, getRegion(where,range,{Char}) do
  1767.         local hum = (v.Parent and v.Parent:FindFirstChildOfClass'Humanoid' or nil)
  1768.       if(hum and not healed[hum])then
  1769.             hum.Health = hum.Health + amount
  1770.             if(v.Parent:FindFirstChild'Head' and hum.Health > 0)then
  1771.               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)
  1772.           end
  1773.         end
  1774.     end
  1775. end
  1776.  
  1777.  
  1778. --// Attack Functions \\--
  1779.  
  1780.  
  1781. function Slash()
  1782.     Attack = true
  1783.     NeutralAnims = false
  1784.     local sound = Sound(Knife,437475935,1,5,false,true,false)
  1785.     for i = 0, 2, 0.1 do
  1786.         swait()
  1787.         local Alpha = .2
  1788.         RJ.C0 = clerp(RJ.C0,CFrame.new(0.0343287587, 0.00629056804, 0.0572580174, 0.943793893, 0.00207689893, 0.330528289, 1.0000764e-06, 0.99998033, -0.00628630351, -0.330534875, 0.00593330665, 0.943775296),Alpha)
  1789.         LH.C0 = clerp(LH.C0,CFrame.new(-0.496478021, -0.990818381, 0.021652732, 0.999878168, 0, 0.0156089365, -9.80779296e-05, 0.99998033, 0.00628268253, -0.0156086385, -0.00628344761, 0.999858379),Alpha)
  1790.         RH.C0 = clerp(RH.C0,CFrame.new(0.498511612, -0.990985274, 0.0154910646, 0.999878168, 0, 0.0156089365, -9.80779296e-05, 0.99998033, 0.00628268253, -0.0156086385, -0.00628344761, 0.999858379),Alpha)
  1791.         LS.C0 = clerp(LS.C0,CFrame.new(-1.32692134, 0.474511296, -0.0055731535, 0.934981823, 0.354351997, 0.0156129003, -0.354479939, 0.93504262, 0.00628374517, -0.0123721063, -0.0114096552, 0.999858379),Alpha)
  1792.         RS.C0 = clerp(RS.C0,CFrame.new(1.12629449, 0.369358033, -0.486052871, 0.490151912, 0.65154773, 0.57899636, 0.721657813, 0.0691910982, -0.688783586, -0.488836735, 0.755445719, -0.436280251),Alpha)
  1793.         NK.C0 = clerp(NK.C0,CFrame.new(-0.0118216109, 1.49854016, -0.0795068145, 0.943793833, 0.0190048125, -0.329988182, 0.00207654224, 0.997985244, 0.0634154305, 0.330528468, -0.0605363287, 0.94185257),Alpha)
  1794.         HW.C0 = HW.C0:lerp(CF.N(0,-1,-1)*CF.A(M.R(-90),0,0),Alpha)
  1795.     end
  1796.     KTrail.Enabled = true
  1797.     sound:Play()
  1798.     for i = 0, 2.5, 0.1 do
  1799.         swait()
  1800.         AOEDamage(Knife.CFrame.p,1,15,30,0,"Normal",0,1)
  1801.         local Alpha = .25
  1802.         RJ.C0 = clerp(RJ.C0,CFrame.new(-0.0352100767, 0.00629066909, -0.0097481478, 0.817972422, -0.00361463916, -0.575246274, -1.74103582e-06, 0.99998033, -0.00628598873, 0.575257719, 0.00514276745, 0.817956269),Alpha)
  1803.         LH.C0 = clerp(LH.C0,CFrame.new(-0.496478021, -0.990818381, 0.0216572341, 0.999878287, 0, 0.015610218, -9.80866607e-05, 0.99998033, 0.00628274865, -0.0156098902, -0.00628351374, 0.999858499),Alpha)
  1804.         RH.C0 = clerp(RH.C0,CFrame.new(0.498511702, -0.990985274, 0.0154905058, 0.999878287, 0, 0.015610218, -9.80866607e-05, 0.99998033, 0.00628274865, -0.0156098902, -0.00628351374, 0.999858499),Alpha)
  1805.         LS.C0 = clerp(LS.C0,CFrame.new(-1.32694602, 0.474510223, -0.00555660389, 0.934981823, 0.354351729, 0.0156157613, -0.354479671, 0.935042739, 0.00628153514, -0.012375474, -0.0114085823, 0.999858379),Alpha)
  1806.         RS.C0 = clerp(RS.C0,CFrame.new(1.23906493, 0.406229913, 0.00231830776, 0.49015066, -0.849889755, 0.193494052, 0.721655607, 0.520183682, 0.456752002, -0.488841236, -0.0842411816, 0.868295968),Alpha)
  1807.         NK.C0 = clerp(NK.C0,CFrame.new(0.0315471888, 1.49887729, -0.0257819965, 0.817972481, -0.0330747738, 0.574305832, -0.00361499586, 0.998030663, 0.0626262054, -0.575246155, -0.0533026271, 0.81624186),Alpha)
  1808.         HW.C0 = HW.C0:lerp(CF.N(0,-1,-1)*CF.A(M.R(-90),0,0),Alpha)
  1809.     end
  1810.     KTrail.Enabled = false
  1811.     Attack = false
  1812.     NeutralAnims = true
  1813. end
  1814.  
  1815. Mouse.Button1Down:connect(function()
  1816.     if(Attack)then return end
  1817.     Slash()
  1818. end)
  1819.  
  1820. Mouse.KeyDown:connect(function(k)
  1821.     if(Attack)then return end
  1822.     if(k == 'z')then AOEKill(Root.CFrame.p,25) end -- TODO: Animation and effects
  1823.   if(k == 'q')then WalkSpeed = (WalkSpeed == 8 and 32 or 8) end  
  1824. end)
  1825.  
  1826.  
  1827. function Refuse()
  1828.     Attack = true
  1829.     warn("But Its ReTurn")
  1830.     local oMH = MaxHealth
  1831.     MaxHealth = "inf"
  1832.     Hum.MaxHealth = "inf"
  1833.     Hum.Health = "inf"
  1834.     Char.Parent = nil
  1835.     Hum:destroy()
  1836.     if(not _G.RefusedAnimation)then
  1837.         _G.RefusedAnimation = true
  1838.        
  1839.    
  1840.         local Soul;
  1841.         function Soul(where,decalId)
  1842.             local destroy = false  
  1843.             local soul = NewInstance("Part",workspace)
  1844.             soul.Name = "Soul"
  1845.             soul.Transparency=1
  1846.             soul.Size = V3.N(2,2,.05)
  1847.             soul.Anchored=true
  1848.             soul.CanCollide=false
  1849.             soul.CFrame = where
  1850.             local heartF = NewInstance("Decal",soul,{Face=Enum.NormalId.Front,Texture="rbxassetid://"..decalId})
  1851.             local heartB = NewInstance("Decal",soul,{Face=Enum.NormalId.Back,Texture="rbxassetid://"..decalId})
  1852.             return soul,heartF,heartB
  1853.         end
  1854.         local owo = Root.CFrame
  1855.         local s,f,b = Soul(owo,1569347904)
  1856.         swait(60)
  1857.         local snd = Sound(s,862552636,1,5,false,false,false)
  1858.         snd:Play()
  1859.         f.Texture = "rbxassetid://1569348344"
  1860.         b.Texture = "rbxassetid://1569348344"
  1861.         swait(15)
  1862.         snd:Stop()
  1863.         swait(60)
  1864.         print'lol'
  1865.       for i = 0, 6, .1 do
  1866.             swait()
  1867.             s.CFrame = owo * CF.N(M.RNG(-50,50)/100,M.RNG(-50,50)/100,M.RNG(-50,50)/100)
  1868.         end
  1869.         local snd = Sound(s,862552636,1,5,false,false,false)
  1870.         snd:Play()
  1871.         s.CFrame = owo
  1872.         f.Texture = "rbxassetid://1569347904"
  1873.         b.Texture = "rbxassetid://1569347904"
  1874.         swait(15)
  1875.         snd:Stop()
  1876.         swait(60)
  1877.    
  1878.         s:destroy()
  1879.     end
  1880.    
  1881.     RJ.Parent = Char
  1882.     LS.Parent = Char
  1883.     RS.Parent = Char
  1884.     LH.Parent = Char
  1885.     RH.Parent = Char
  1886.     NK.Parent = Char
  1887.    
  1888.     LArm.Parent = Char
  1889.     RArm.Parent = Char
  1890.     LLeg.Parent = Char
  1891.     LArm.Parent = Char
  1892.     Root.Parent = Char
  1893.     Torso.Parent = Char
  1894.     Head.Parent = Char
  1895.    
  1896.     Knife.Parent = Char
  1897.     Hair.Parent = Char
  1898.    
  1899.     HW.Parent = Char
  1900.     HW2.Parent = Char
  1901.    
  1902.  
  1903.     REye:destroy()
  1904.     LEye:destroy()
  1905.    
  1906.     for _,v in next, Char:children() do
  1907.         if(v.Name == 'ShadowFace')then v:destroy() end
  1908.   end
  1909.     LEye = Part(Char,C3.N(1,0,0),Enum.Material.Neon,V3.N(.15,.25,.2),CF.N(),false,false)
  1910.     LEyeM = Mesh(LEye,Enum.MeshType.Sphere,"","",V3.N(1,1,1),V3.N())
  1911.     LEyeW = NewInstance("Weld",LEye,{Part0=Head,Part1=LEye,C0=CF.N(-.2,.2,-.49)})
  1912.    
  1913.     REye = Part(Char,C3.N(1,0,0),Enum.Material.Neon,V3.N(.15,.25,.2),CF.N(),false,false)
  1914.     REyeM = Mesh(REye,Enum.MeshType.Sphere,"","",V3.N(1,1,1),V3.N())
  1915.     REyeW = NewInstance("Weld",REye,{Part0=Head,Part1=REye,C0=CF.N(.2,.2,-.49)})
  1916.     for i = 1, 35 do
  1917.         local FACE = Part(Char,C3.N(0,0,0),Enum.Material.Neon,V3.N(1.01,.5,1.01),CF.N(),false,false)
  1918.         FACE.Transparency = 0+(i-1)/35.2
  1919.         FACE.Name = 'ShadowFace'
  1920.       Head:FindFirstChildOfClass("SpecialMesh"):Clone().Parent = FACE
  1921.         NewInstance("Weld",Head,{Part0=Head,Part1=FACE,C0=CF.N(0,.35-(i-1)/75,0)})
  1922.         --CreateWeldOrSnapOrMotor("Weld", Head, Head, FACE, CF(0,0.35-(i-1)/75,0), CF(0, 0, 0))
  1923.     end
  1924.     Hum = NewInstance("Humanoid",Char,{DisplayDistanceType='None'})
  1925.   ConnectHum()
  1926.     MaxHealth = oMH
  1927.     Hum.MaxHealth = MaxHealth
  1928.     Hum.Health = MaxHealth
  1929.     swait(5)
  1930.     Char.Parent = workspace
  1931.    
  1932.     Attack = false
  1933. end
  1934.  
  1935. function ConnectHum()
  1936.     Hum.Died:connect(Refuse)
  1937. end
  1938. ConnectHum()
  1939.  
  1940.  
  1941. --// Wrap it all up \\--
  1942. while true do
  1943.     swait()
  1944.     Sine = Sine + Change
  1945.     if(not Music)then
  1946.         Music = Sound(Torso,MusicID,1,3,true,false,true)
  1947.         Music.Name = 'Music'
  1948.   end
  1949.     Music.Pitch = 1
  1950.     Music.Volume = 5
  1951.     Music.SoundId = "rbxassetid://"..MusicID
  1952.     Music.Parent = Torso
  1953.     Music:Resume()
  1954.     local hitfloor,posfloor = workspace:FindPartOnRay(Ray.new(Root.CFrame.p,((CFrame.new(Root.Position,Root.Position - Vector3.new(0,1,0))).lookVector).unit * 4), Char)
  1955.     local Walking = (math.abs(Root.Velocity.x) > 1 or math.abs(Root.Velocity.z) > 1)
  1956.     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 "Walk" or hitfloor and "Idle")
  1957.   if(not Effects or not Effects.Parent)then
  1958.         Effects = IN("Model",Char)
  1959.         Effects.Name = "Effects"
  1960.     end
  1961.     Hum.WalkSpeed = WalkSpeed
  1962.     if(State == 'Walk')then
  1963.       if(Hum.WalkSpeed >= 24)then
  1964.             local wsVal = 22 / (Hum.WalkSpeed/16)
  1965.             local Alpha = math.min(.1 * (Hum.WalkSpeed/16),1)
  1966.             Change = 2
  1967.             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(25+45*M.C(Sine/wsVal))+-M.S(Sine/wsVal),0,0),Alpha)
  1968.             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(25-45*M.C(Sine/wsVal))+M.S(Sine/wsVal),0,0),Alpha)
  1969.         else
  1970.             Change = .9
  1971.             local wsVal = 8 / (Hum.WalkSpeed/8)
  1972.             local Alpha = math.min(.2 * (Hum.WalkSpeed/8),1)
  1973.             LH.C1 = LH.C1:lerp(CF.N(0,1-.2*M.C(Sine/wsVal)/2,.4*M.C(Sine/wsVal)/2)*CF.A(M.R(15-2*M.C(Sine/wsVal))-M.S(Sine/wsVal)/2.5,0,0)*CF.A(M.R(0-3*M.C(Sine/wsVal)),0,0),Alpha)
  1974.             RH.C1 = RH.C1:lerp(CF.N(0,1+.2*M.C(Sine/wsVal)/2,-.4*M.C(Sine/wsVal)/2)*CF.A(M.R(15+2*M.C(Sine/wsVal))+M.S(Sine/wsVal)/2.5,0,0)*CF.A(M.R(0+3*M.C(Sine/wsVal)),0,0),Alpha)
  1975.         end
  1976.     else
  1977.         RH.C1 = RH.C1:lerp(CF.N(0,1,0),.1)
  1978.         LH.C1 = LH.C1:lerp(CF.N(0,1,0),.1)
  1979.     end
  1980.     for _,v in next, Char:children() do
  1981.         if(v:IsA'Accessory')then
  1982.           v:destroy()
  1983.         elseif(v:IsA'Shirt')then
  1984.           v.ShirtTemplate = "rbxassetid://344089667"
  1985.         elseif(v:IsA'Pants')then
  1986.           v.PantsTemplate = "rbxassetid://344084364"
  1987.         elseif(v:IsA'CharacterMesh')then
  1988.           v:destroy()
  1989.         elseif(v:FindFirstChildOfClass'ShirtGraphic')then
  1990.           v:FindFirstChildOfClass'ShirtGraphic':destroy()
  1991.       end
  1992.     end
  1993.     local face = Head:FindFirstChild'face'
  1994.   if(not face)then
  1995.         NewInstance("Decal",Head,{Name='face',Face=Enum.NormalId.Front,Texture="rbxassetid://404306534"})
  1996.   else
  1997.         face.Texture = "rbxassetid://946610608"
  1998.     end
  1999.     RArm.BrickColor = BrickColor.new'Pastel brown'
  2000.   LArm.BrickColor = BrickColor.new'Pastel brown'
  2001.   RLeg.BrickColor = BrickColor.new'Pastel brown'
  2002.   LLeg.BrickColor = BrickColor.new'Pastel brown'
  2003.   Torso.BrickColor = BrickColor.new'Pastel brown'
  2004.   Head.BrickColor = BrickColor.new'Pastel brown'
  2005.   Hum.Name = 'Chara'
  2006.   if(Hum.MaxHealth ~= MaxHealth)then
  2007.         Hum.MaxHealth = MaxHealth
  2008.     end
  2009.     Hum.DisplayDistanceType='None'
  2010.   if(NeutralAnims)then  
  2011.         if(State == 'Idle')then
  2012.           Change = 1
  2013.             local Alpha = .1
  2014.             RJ.C0 = clerp(RJ.C0,CFrame.new(-0.0999571308, 0+.05*M.C(Sine/16), -0.237876296, 0.857335567, -0.00323621999, -0.514731407, 0, 0.99998033, -0.00628707698, 0.51474154, 0.00539013464, 0.85731858),Alpha)
  2015.             LH.C0 = clerp(LH.C0,CFrame.new(-0.536091685, -0.991042495-.05*M.C(Sine/16), -0.0134909991, 0.849195242, 0, 0.528063774, -0.00331997755, 0.99998033, 0.00533895614, -0.528053343, -0.00628707698, 0.849178433),Alpha)
  2016.             RH.C0 = clerp(RH.C0,CFrame.new(0.529067397, -0.991597891-.05*M.C(Sine/16), -0.0818087086, 0.849195242, 0, 0.528063774, -0.00331997755, 0.99998033, 0.00533895614, -0.528053343, -0.00628707698, 0.849178433),Alpha)
  2017.             LS.C0 = clerp(LS.C0,CFrame.new(-1.32175505, 0.156236127+.15*M.C(Sine/16), 0.233877867, 0.877554953, -0.456876248, 0.145469457, 0.259513229, 0.707695842, 0.657129884, -0.403175086, -0.538916171, 0.739607573),Alpha)
  2018.             RS.C0 = clerp(RS.C0,CFrame.new(1.2516855, 0.604915917+.15*M.C(Sine/16), -0.0189059302, 0.915104508, -0.287113011, -0.283108115, 0.301054537, 0.953587949, 0.00603589695, 0.268235415, -0.0907544345, 0.959069014),Alpha)
  2019.             NK.C0 = clerp(NK.C0,CFrame.new(1.79447234e-05, 1.49895597, -0.0143749639, 0.769539058, -0.360377938, 0.527197778, 0.387706369, 0.919646919, 0.0627188534, -0.507438183, 0.156133309, 0.847424924),Alpha)
  2020.             HW.C0 = HW.C0:lerp(CF.N(0,-1,-1)*CF.A(M.R(-90),0,0),Alpha)
  2021.             -- idle
  2022.         elseif(State == 'Walk')then
  2023.           if(Hum.WalkSpeed >= 24)then
  2024.                 local wsVal = 22 / (Hum.WalkSpeed/16)
  2025.                 local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1)
  2026.                 RJ.C0 = RJ.C0:lerp(CF.N(0,0-.15*M.C(Sine/(wsVal/2)),0)*CF.A(M.R(-15),M.R(0-15*M.S(Sine/wsVal)/2),0),Alpha)
  2027.                 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+15*M.S(Sine/wsVal))),Alpha)
  2028.                 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+15*M.S(Sine/wsVal))),Alpha)
  2029.                 NK.C0 = NK.C0:lerp(NKC0*CF.A(M.R(15),0,0),Alpha)
  2030.                 LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0+.15*M.C(Sine/(wsVal/2)),0)*CF.A(M.R(15),0,0),Alpha)
  2031.                 RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0+.15*M.C(Sine/(wsVal/2)),0)*CF.A(M.R(15),0,0),Alpha)
  2032.                 HW.C0 = HW.C0:lerp(CF.N(0,-1,-1)*CF.A(M.R(-90),0,0),Alpha)
  2033.             else
  2034.                 local wsVal = 8 / (Hum.WalkSpeed/8)
  2035.                 local Alpha = math.min(.2 * (Hum.WalkSpeed/8),1)
  2036.                 RJ.C0 = RJ.C0:lerp(CF.N(0,0-.05*M.C(Sine/(wsVal/2)),0)*CF.A(0,M.R(0-5*M.S(Sine/wsVal)/2),0),Alpha)
  2037.                 LS.C0 = LS.C0:lerp(LSC0*CF.N(0,0,0+.3*M.S(Sine/wsVal))*CF.A(M.R(0-25*M.S(Sine/wsVal)),0,M.R(5-5*M.S(Sine/wsVal))),Alpha)
  2038.                 RS.C0 = RS.C0:lerp(RSC0*CF.N(0,0,0-.3*M.S(Sine/wsVal))*CF.A(M.R(0+25*M.S(Sine/wsVal)),0,M.R(-5-5*M.S(Sine/wsVal))),Alpha)
  2039.                 NK.C0 = NK.C0:lerp(NKC0,Alpha)
  2040.                 LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0+.05*M.C(Sine/(wsVal/2)),0),Alpha)
  2041.                 RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0+.05*M.C(Sine/(wsVal/2)),0),Alpha)
  2042.                 HW.C0 = HW.C0:lerp(CF.N(0,-1,-1)*CF.A(M.R(-90),0,0),Alpha)
  2043.             end
  2044.         elseif(State == 'Jump' or State == 'Fall')then
  2045.           if(Walking)then
  2046.                 local Alpha = .2
  2047.                 RJ.C0 = clerp(RJ.C0,RJC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(65)),M.R(65)),0,0),Alpha)
  2048.                 LH.C0 = clerp(LH.C0,CFrame.new(-0.497912645, -1.0987643, -0.0683324337, 0.999878228, 0.00860835519, 0.0130246133, -0.00010142161, 0.837816596, -0.545952022, -0.015611981, 0.545884132, 0.837715328),Alpha)
  2049.                 RH.C0 = clerp(RH.C0,CFrame.new(0.499978393, -1.16382337, 0.109293163, 0.999878228, -0.0120433727, 0.00993486121, -0.00010142161, 0.631323814, 0.775519371, -0.015611981, -0.775425911, 0.631245613),Alpha)
  2050.                 LS.C0 = clerp(LS.C0,CFrame.new(-1.55211556, 0.576563478, -0.00269976072, 0.976067662, 0.216906726, 0.0156116467, -0.217024669, 0.976145923, 0.00628317893, -0.0138763804, -0.00952091813, 0.999858499),Alpha)
  2051.                 RS.C0 = clerp(RS.C0,CFrame.new(1.50182188, 0.636661649, 0.00632623257, 0.977592707, -0.209926367, 0.0156121543, 0.209851891, 0.977713108, 0.00628198683, -0.016582964, -0.00286500831, 0.999858439),Alpha)
  2052.                 NK.C0 = clerp(NK.C0,CFrame.new(1.14440072e-05, 1.49924362, -0.0143961608, 1.00000024, -5.82076609e-11, 0, 1.23691279e-10, 0.997964919, 0.0637660474, 0, -0.0637660623, 0.997965038),Alpha)
  2053.                 HW.C0 = HW.C0:lerp(CF.N(0,-1,-1)*CF.A(M.R(-90),0,0),Alpha)
  2054.             else
  2055.                 local Alpha = .2
  2056.                 RJ.C0 = clerp(RJ.C0,RJC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(65)),M.R(65)),0,0),Alpha)
  2057.                 LH.C0 = clerp(LH.C0,CFrame.new(-0.504374504, -0.291219354, -0.487436086, 0.999878228, -0.00438931212, 0.0149825988, -0.00010142161, 0.957819223, 0.287371844, -0.015611981, -0.287338346, 0.957701981),Alpha)
  2058.                 RH.C0 = clerp(RH.C0,CFrame.new(0.453094482, -0.871358454, 0.0898642987, 0.985589385, -0.168456957, 0.0153662469, 0.162863791, 0.969548643, 0.182895929, -0.0457084104, -0.177757636, 0.983012319),Alpha)
  2059.                 LS.C0 = clerp(LS.C0,CFrame.new(-1.55211556, 0.576563478, -0.00269976072, 0.976067662, 0.216906726, 0.0156116467, -0.217024669, 0.976145923, 0.00628317893, -0.0138763804, -0.00952091813, 0.999858499),Alpha)
  2060.                 RS.C0 = clerp(RS.C0,CFrame.new(1.50182188, 0.636661649, 0.00632623257, 0.977592707, -0.209926367, 0.0156121543, 0.209851891, 0.977713108, 0.00628198683, -0.016582964, -0.00286500831, 0.999858439),Alpha)
  2061.                 NK.C0 = clerp(NK.C0,CFrame.new(1.14440072e-05, 1.49924362, -0.0143961608, 1.00000024, -5.82076609e-11, 0, 1.23691279e-10, 0.997964919, 0.0637660474, 0, -0.0637660623, 0.997965038),Alpha)
  2062.                 HW.C0 = HW.C0:lerp(CF.N(0,-1,-1)*CF.A(M.R(-90),0,0),Alpha)
  2063.             end
  2064.         elseif(State == 'Paralyzed')then
  2065.           -- paralyzed
  2066.         elseif(State == 'Sit')then
  2067.           -- sit
  2068.         end
  2069.     end
  2070. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement