Advertisement
idkwhatiam

Classic Kirby V1

Apr 17th, 2019
291
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 26.91 KB | None | 0 0
  1. -----------//CLASSIC KIRBY\\-----------
  2. --[[Movelist
  3. Q = Inhale [can be abusive if you eat people with it]
  4. ---------]]
  5.  
  6. --Hey! thanks for using this script. My base was KrystalDance V2, Not sure why.
  7. --But anyway, heres my script!
  8.  
  9. if game:GetService("RunService"):IsClient()then error("Please run as a server script. Use h/ instead of hl/.")end;print("FE Compatibility: by WaverlyCole");InternalData = {}
  10. do
  11.     script.Parent = owner.Character
  12.     local Event = Instance.new("RemoteEvent");Event.Name = "UserInput"
  13.     local function NewFakeEvent()
  14.         local Bind = Instance.new("BindableEvent")
  15.         local Fake;Fake = {Connections = {},
  16.         fakeEvent=true;
  17.         Connect=function(self,Func)
  18.             Bind.Event:connect(Func)
  19.             self.Connections[Bind] = true
  20.             return setmetatable({Connected = true},{
  21.             __index = function (self,Index)
  22.                 if Index:lower() == "disconnect" then
  23.                     return function() Fake.Connections[Bind] = false;self.Connected = false end
  24.                 end
  25.                 return Fake[Index]
  26.             end;
  27.             __tostring = function() return "Connection" end;
  28.         })
  29.         end}
  30.         Fake.connect = Fake.Connect;return Fake;
  31.     end
  32.     local Mouse = {Target=nil,Hit=CFrame.new(),KeyUp=NewFakeEvent(),KeyDown=NewFakeEvent(),Button1Up=NewFakeEvent(),Button1Down=NewFakeEvent()}
  33.     local UserInputService = {InputBegan=NewFakeEvent(),InputEnded=NewFakeEvent()}
  34.     local ContextActionService = {Actions={},BindAction = function(self,actionName,Func,touch,...)
  35.         self.Actions[actionName] = Func and {Name=actionName,Function=Func,Keys={...}} or nil
  36.     end};ContextActionService.UnBindAction = ContextActionService.BindAction
  37.     local function TriggerEvent(self,Event,...)
  38.         local Trigger = Mouse[Event]
  39.         if Trigger and Trigger.fakeEvent and Trigger.Connections then
  40.             for Connection,Active in pairs(Trigger.Connections) do if Active then Connection:Fire(...) end end
  41.         end
  42.     end
  43.     Mouse.TrigEvent = TriggerEvent;UserInputService.TrigEvent = TriggerEvent
  44.     Event.OnServerEvent:Connect(function(FiredBy,Input)
  45.         if FiredBy.Name ~= owner.Name then return end
  46.         if Input.MouseEvent then
  47.             Mouse.Target = Input.Target;Mouse.Hit = Input.Hit
  48.         else
  49.             local Begin = Input.UserInputState == Enum.UserInputState.Begin
  50.             if Input.UserInputType == Enum.UserInputType.MouseButton1 then return Mouse:TrigEvent(Begin and "Button1Down" or "Button1Up") end
  51.             for _,Action in pairs(ContextActionService.Actions) do
  52.                 for _,Key in pairs(Action.Keys) do if Key==Input.KeyCode then Action.Function(Action.Name,Input.UserInputState,Input) end end
  53.             end
  54.             Mouse:TrigEvent(Begin and "KeyDown" or "KeyUp",Input.KeyCode.Name:lower())
  55.             UserInputService:TrigEvent(Begin and "InputBegan" or "InputEnded",Input,false)
  56.         end
  57.     end)
  58.     InternalData["Mouse"] = Mouse;InternalData["ContextActionService"] = ContextActionService;InternalData["UserInputService"] = UserInputService
  59.     Event.Parent = NLS([[
  60.         local Player = owner;local Event = script:WaitForChild("UserInput");local UserInputService = game:GetService("UserInputService");local Mouse = Player:GetMouse()
  61.         local Input = function(Input,gameProcessedEvent)
  62.             if gameProcessedEvent then return end
  63.             Event:FireServer({KeyCode=Input.KeyCode,UserInputType=Input.UserInputType,UserInputState=Input.UserInputState})
  64.         end
  65.         UserInputService.InputBegan:Connect(Input);UserInputService.InputEnded:Connect(Input)
  66.         local Hit,Target
  67.         while wait(1/30) do
  68.             if Hit ~= Mouse.Hit or Target ~= Mouse.Target then
  69.                 Hit,Target = Mouse.Hit,Mouse.Target;Event:FireServer({["MouseEvent"]=true,["Target"]=Target,["Hit"]=Hit})
  70.             end
  71.         end
  72.     ]],owner.Character)
  73. end
  74. RealGame = game;game = setmetatable({},{
  75.     __index = function (self,Index)
  76.         local Sandbox = function (Thing)
  77.             if Thing:IsA("Player") then
  78.                 local RealPlayer = Thing
  79.                 return setmetatable({},{
  80.                     __index = function (self,Index)
  81.                         local Type = type(RealPlayer[Index])
  82.                         if Type == "function" then
  83.                             if Index:lower() == "getmouse" or Index:lower() == "mouse" then
  84.                                 return function (self)return InternalData["Mouse"] end
  85.                             end
  86.                             return function (self,...)return RealPlayer[Index](RealPlayer,...) end
  87.                         end
  88.                         return RealPlayer[Index]
  89.                     end;
  90.                     __tostring = function(self) return RealPlayer.Name end
  91.                 })
  92.             end
  93.         end
  94.         if RealGame[Index] then
  95.             local Type = type(RealGame[Index])
  96.             if Type == "function" then
  97.                 if Index:lower() == "getservice" or Index:lower() == "service" then
  98.                     return function (self,Service)
  99.                         local FakeServices = {
  100.                             ["players"] = function()
  101.                                 return setmetatable({},{
  102.                                     __index = function (self2,Index2)
  103.                                         local RealService = RealGame:GetService(Service)
  104.                                         local Type2 = type(Index2)
  105.                                         if Type2 == "function" then
  106.                                             return function (self,...) return RealService[Index2](RealService,...)end
  107.                                         else
  108.                                             if Index2:lower() == "localplayer" then return Sandbox(owner) end
  109.                                             return RealService[Index2]
  110.                                         end
  111.                                     end;
  112.                                     __tostring = function(self) return RealGame:GetService(Service).Name end
  113.                                 })
  114.                             end;
  115.                             ["contextactionservice"] = function() return InternalData["ContextActionService"] end;
  116.                             ["userinputservice"] = function() return InternalData["UserInputService"] end;
  117.                             ["runservice"] = function()
  118.                                 return setmetatable({},{
  119.                                     __index = function(self2,Index2)
  120.                                         local RealService = RealGame:GetService(Service)
  121.                                         local Type2 = type(Index2)
  122.                                         if Type2 == "function" then
  123.                                             return function (self,...) return RealService[Index2](RealService,...) end
  124.                                         else
  125.                                             local RunServices = {
  126.                                                 ["bindtorenderstep"] = function() return function (self,Name,Priority,Function) return RealGame:GetService("RunService").Stepped:Connect(Function) end end;
  127.                                                 ["renderstepped"] = function() return RealService["Stepped"] end
  128.                                             }
  129.                                             if RunServices[Index2:lower()] then return RunServices[Index2:lower()]() end
  130.                                             return RealService[Index2]
  131.                                         end
  132.                                     end
  133.                                 })
  134.                             end
  135.                         }
  136.                         if FakeServices[Service:lower()] then return FakeServices[Service:lower()]() end
  137.                         return RealGame:GetService(Service)
  138.                     end
  139.                 end
  140.                 return function (self,...) return RealGame[Index](RealGame,...) end
  141.             else
  142.                 if game:GetService(Index) then return game:GetService(Index) end
  143.                 return RealGame[Index]
  144.             end
  145.         end
  146.         return nil
  147.     end
  148. });Game = game;owner = game:GetService("Players").LocalPlayer;script = Instance.new("Script");print("Complete! Running...")
  149.  
  150. Player=game.Players.LocalPlayer
  151. Character=Player.Character
  152. Character.Humanoid.Name = "noneofurbusiness"
  153. hum = Character.noneofurbusiness
  154. LeftArm=Character["Left Arm"]
  155. LeftLeg=Character["Left Leg"]
  156. RightArm=Character["Right Arm"]
  157. RightLeg=Character["Right Leg"]
  158. Root=Character["HumanoidRootPart"]
  159. Head=Character["Head"]
  160. Torso=Character["Torso"]
  161. Neck=Torso["Neck"]
  162. mouse = Player:GetMouse()
  163. walking = false
  164. jumping = false
  165. attacking = false
  166. firsttime = false
  167. tauntdebounce = false
  168. position = nil
  169. MseGuide = true
  170. running = false
  171. settime = 0
  172. sine = 0
  173. t = 0
  174. ws = 14
  175. change = 1
  176. combo1 = true
  177. dancing = false
  178. equip = false
  179. dgs = 75
  180. combo2 = false
  181. switch1 = true
  182. switch2 = false
  183. firsttime2 = false
  184. combo3 = false
  185. gunallowance = false
  186. shooting = false
  187. RunSrv = game:GetService("RunService")
  188. RenderStepped = game:GetService("RunService").RenderStepped
  189. removeuseless = game:GetService("Debris")
  190.  
  191. screenGui = Instance.new("ScreenGui")
  192. screenGui.Parent = script.Parent
  193.  
  194. local HEADLERP = Instance.new("ManualWeld")
  195. HEADLERP.Parent = Head
  196. HEADLERP.Part0 = Head
  197. HEADLERP.Part1 = Head
  198. HEADLERP.C0 = CFrame.new(0, -1.5, -0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  199.  
  200. local TORSOLERP = Instance.new("ManualWeld")
  201. TORSOLERP.Parent = Root
  202. TORSOLERP.Part0 = Torso
  203. TORSOLERP.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  204.  
  205. local ROOTLERP = Instance.new("ManualWeld")
  206. ROOTLERP.Parent = Root
  207. ROOTLERP.Part0 = Root
  208. ROOTLERP.Part1 = Torso
  209. ROOTLERP.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  210.  
  211. local RIGHTARMLERP = Instance.new("ManualWeld")
  212. RIGHTARMLERP.Parent = RightArm
  213. RIGHTARMLERP.Part0 = RightArm
  214. RIGHTARMLERP.Part1 = Torso
  215. RIGHTARMLERP.C0 = CFrame.new(-1.5, 0, -0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  216.  
  217. local LEFTARMLERP = Instance.new("ManualWeld")
  218. LEFTARMLERP.Parent = LeftArm
  219. LEFTARMLERP.Part0 = LeftArm
  220. LEFTARMLERP.Part1 = Torso
  221. LEFTARMLERP.C0 = CFrame.new(1.5, 0, -0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  222.  
  223. local RIGHTLEGLERP = Instance.new("ManualWeld")
  224. RIGHTLEGLERP.Parent = RightLeg
  225. RIGHTLEGLERP.Part0 = RightLeg
  226. RIGHTLEGLERP.Part1 = Torso
  227. RIGHTLEGLERP.C0 = CFrame.new(-0.5, 2, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  228.  
  229. local LEFTLEGLERP = Instance.new("ManualWeld")
  230. LEFTLEGLERP.Parent = LeftLeg
  231. LEFTLEGLERP.Part0 = LeftLeg
  232. LEFTLEGLERP.Part1 = Torso
  233. LEFTLEGLERP.C0 = CFrame.new(0.5, 2, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  234.  
  235. local function weldBetween(a, b)
  236.     local weld = Instance.new("ManualWeld", a)
  237.     weld.Part0 = a
  238.     weld.Part1 = b
  239.     weld.C0 = a.CFrame:inverse() * b.CFrame
  240.     return weld
  241. end
  242.  
  243. function MAKETRAIL(PARENT,POSITION1,POSITION2,LIFETIME,COLOR)
  244. A = Instance.new("Attachment", PARENT)
  245. A.Position = POSITION1
  246. A.Name = "A"
  247. B = Instance.new("Attachment", PARENT)
  248. B.Position = POSITION2
  249. B.Name = "B"
  250. tr1 = Instance.new("Trail", PARENT)
  251. tr1.Attachment0 = A
  252. tr1.Attachment1 = B
  253. tr1.Enabled = true
  254. tr1.Lifetime = LIFETIME
  255. tr1.TextureMode = "Static"
  256. tr1.LightInfluence = 0
  257. tr1.Color = COLOR
  258. tr1.Transparency = NumberSequence.new(0, 1)
  259. end
  260.  
  261.  
  262.  
  263.  
  264. for i,v in pairs(Character:GetChildren()) do
  265. if v.ClassName == "Shirt" or v.ClassName == "Pants" or v.ClassName == "Hat" or v.ClassName == "CharacterMesh" or v.ClassName == "Shirt Graphic" then
  266. v:Remove()
  267. end
  268. end
  269.  
  270. coroutine.wrap(function()
  271. while wait() do
  272. Head.face.Texture = "rbxassetid://0"
  273. hum.WalkSpeed = ws
  274. LeftArm.Transparency = 1
  275. RightArm.Transparency = 1
  276. Head.Transparency = 1
  277. Torso.Transparency = 0
  278. LeftLeg.Transparency = 0
  279. RightLeg.Transparency = 0
  280. Torso.BrickColor = BrickColor.new("Carnation pink")
  281. LeftLeg.BrickColor = BrickColor.new("Bright red")
  282. LeftLeg.BrickColor = BrickColor.new("Bright red")
  283. end
  284. end)()
  285.  
  286.  
  287. coroutine.wrap(function()
  288. for i,v in pairs(Character:GetChildren()) do
  289. if v.Name == "Animate" then v:Remove()
  290. end
  291. end
  292. end)()
  293.  
  294. function damagealll(Radius,Position)      
  295.     local Returning = {}      
  296.     for _,v in pairs(workspace:GetChildren()) do      
  297.         if v~=Character and v:FindFirstChildOfClass('Humanoid') and v:FindFirstChild('Torso') or v:FindFirstChild('UpperTorso') then
  298. if v:FindFirstChild("Torso") then      
  299.             local Mag = (v.Torso.Position - Position).magnitude    
  300.             if Mag < Radius then      
  301.                 table.insert(Returning,v)      
  302.             end
  303. elseif v:FindFirstChild("UpperTorso") then
  304.             local Mag = (v.UpperTorso.Position - Position).magnitude      
  305.             if Mag < Radius then      
  306.                 table.insert(Returning,v)      
  307.             end
  308. end
  309.         end    
  310.     end    
  311.     return Returning      
  312. end
  313.  
  314. ArtificialHB = Instance.new("BindableEvent", script)
  315. ArtificialHB.Name = "Heartbeat"
  316. script:WaitForChild("Heartbeat")
  317.  
  318. frame = 1 / 60
  319. tf = 0
  320. allowframeloss = false
  321. tossremainder = false
  322.  
  323.  
  324. lastframe = tick()
  325. script.Heartbeat:Fire()
  326.  
  327.  
  328. game:GetService("RunService").Heartbeat:connect(function(s, p)
  329.     tf = tf + s
  330.     if tf >= frame then
  331.         if allowframeloss then
  332.             script.Heartbeat:Fire()
  333.             lastframe = tick()
  334.         else
  335.             for i = 1, math.floor(tf / frame) do
  336.                 script.Heartbeat:Fire()
  337.             end
  338.             lastframe = tick()
  339.         end
  340.         if tossremainder then
  341.             tf = 0
  342.         else
  343.             tf = tf - frame * math.floor(tf / frame)
  344.         end
  345.     end
  346. end)
  347.  
  348. function swait(num)
  349.     if num == 0 or num == nil then
  350.         game:service("RunService").Stepped:wait(0)
  351.     else
  352.         for i = 0, num do
  353.             game:service("RunService").Stepped:wait(0)
  354.         end
  355.     end
  356. end
  357.  
  358. for _,n in pairs(Character:GetChildren()) do
  359. if n:IsA("Accessory") then n:Remove() end
  360. end
  361. for _,x in pairs(Character:GetChildren()) do
  362. if x:IsA("Decal") then x:Remove() end
  363. end
  364.  
  365. ws = 14
  366.  
  367. function SOUND(PARENT,ID,VOL,LOOP,REMOVE)
  368. so = Instance.new("Sound")
  369. so.Parent = PARENT
  370. so.SoundId = "rbxassetid://"..ID
  371. so.Volume = VOL
  372. so.Looped = LOOP
  373.  
  374. so:Play()
  375. removeuseless:AddItem(so,REMOVE)
  376. end
  377.  
  378. mouse.KeyDown:connect(function(Press)
  379. Press=Press:lower()
  380. if Press=='q' then
  381. if dancing then
  382. dancing = false
  383. else
  384. dancing = true
  385. ws = 0
  386. change = .5
  387. attacking = true
  388. lol90 = 0
  389. coroutine.wrap(function()
  390. while dancing do
  391. wind = Instance.new("Part")
  392. wind.Orientation = Torso.Orientation + Vector3.new(90, 0, 0)
  393. wind.Position = Torso.Position
  394. wind.BrickColor = BrickColor.new("Institutional white")
  395. weld = Instance.new("Weld")
  396. weld.Parent = wind
  397. weld.Part0 = wind
  398. weld.Part1 = Torso
  399. mwind = Instance.new("SpecialMesh")
  400. mwind.Parent = wind
  401. mwind.MeshId = "rbxassetid://2196834758"
  402. mwind.Offset = Vector3.new(0, 0, 5)
  403. mwind.Scale = Vector3.new(10, 15, 10)
  404. function suck(hit)
  405.     torso = hit.Parent:FindFirstChild("Torso")
  406.     weld = Instance.new("Weld")
  407.     weld.Name = "KirbySuckWeld"
  408.     weld.Parent = torso
  409.     weld.Part0 = torso
  410.     weld.Part1 = Torso
  411. end
  412. wind.Touched:Connect(suck)
  413. lol90 = lol90 + 11
  414. ROOTLERP.C0 = ROOTLERP.C0:Lerp(CFrame.new(1 * math.sin(sine/10),.1 + .8 * math.sin(sine/3),0) * CFrame.Angles(math.rad(0),math.rad(0 * math.sin(sine/8)),math.rad(8 * math.sin(sine/7))),.25)
  415. ROOTLERP.C1 = ROOTLERP.C1:lerp(CFrame.new(0 * math.sin(sine/14),0,0) * CFrame.Angles(math.rad(0),math.rad(lol90),0),.25)
  416. LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(CFrame.new(1.4,1.45,0) * CFrame.Angles(math.rad(180),math.rad(-5 * math.sin(sine/3)),math.rad(-6 * math.sin(sine/3))),0.25)
  417. RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(CFrame.new(-1.4,1.45,0) * CFrame.Angles(math.rad(180),math.rad(5 * math.sin(sine/3)),math.rad(6 * math.sin(sine/3))), 0.25)
  418. RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(CFrame.new(-0.3, 2 , 0) * CFrame.Angles(0, math.rad(0), math.rad(-10 + 5 * math.sin(sine/3))), 0.25)
  419. LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(CFrame.new(0.3, 2.0, 0) * CFrame.Angles(0, math.rad(0), math.rad(10 - 5 * math.sin(sine/3))), 0.25)
  420. swait()
  421. end
  422. ws = 14
  423. wind:Remove()
  424. ROOTLERP.C1 = CFrame.new(0,0,0) * CFrame.Angles(math.rad(0),math.rad(0),math.rad(0))
  425. attacking = false
  426. end)()
  427. end
  428. end
  429. end)
  430.  
  431.  
  432.  
  433.  
  434.  
  435. function ray(pos, dir, rang, ignoredesc)
  436.     return workspace:FindPartOnRay(Ray.new(pos, dir.unit * rang), ignoredesc)
  437. end
  438.  
  439. function ray2(startpos, endpos, distance, ignore)
  440. local dir = CFrame.new(startpos,endpos).lookVector
  441. return ray(startpos, dir, distance, ignore)
  442. end
  443.  
  444. checks1 = coroutine.wrap(function() -------Checks
  445. while true do
  446. hf = ray(Root.Position,(CFrame.new(Root.Position,Root.Position+Vector3.new(0,-1,0))).lookVector,3*3,Character)
  447. if Root.Velocity.y > 1 then
  448. position = "Jump"
  449. elseif Root.Velocity.y < -1 then
  450. position = "Falling"
  451. elseif Root.Velocity.Magnitude < 2 then
  452. position = "Idle"
  453. elseif Root.Velocity.Magnitude > 2 then
  454. position = "Walking"
  455. elseif Root.Velocity.Magnitude > 20 then
  456. position = "Running"
  457. else
  458. end
  459. wait()
  460. end
  461. end)
  462. checks1()
  463.  
  464. function ray(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS)
  465.     return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS)
  466. end
  467.  
  468. function ray2(StartPos, EndPos, Distance, Ignore)
  469. local DIRECTION = CFrame.new(StartPos,EndPos).lookVector
  470. return ray(StartPos, DIRECTION, Distance, Ignore)
  471. end
  472.  
  473. OrgnC0 = Neck.C0
  474. local movelimbs = coroutine.wrap(function()
  475. while RunSrv.RenderStepped:wait() do
  476. TrsoLV = Torso.CFrame.lookVector
  477. Dist = nil
  478. Diff = nil
  479. if not MseGuide then
  480. print("Failed to recognize")
  481. else
  482. local _, Point = Workspace:FindPartOnRay(Ray.new(Head.CFrame.p, mouse.Hit.lookVector), Workspace, false, true)
  483. Dist = (Head.CFrame.p-Point).magnitude
  484. Diff = Head.CFrame.Y-Point.Y
  485. local _, Point2 = Workspace:FindPartOnRay(Ray.new(LeftArm.CFrame.p, mouse.Hit.lookVector), Workspace, false, true)
  486. Dist2 = (LeftArm.CFrame.p-Point).magnitude
  487. Diff2 = LeftArm.CFrame.Y-Point.Y
  488. HEADLERP.C0 = CFrame.new(0, -1.5, -0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  489. Neck.C0 = Neck.C0:lerp(OrgnC0*CFrame.Angles((math.tan(Diff/Dist)*1), 0, (((Head.CFrame.p-Point).Unit):Cross(Torso.CFrame.lookVector)).Y*1), .1)
  490. end
  491. end
  492. end)
  493. movelimbs()
  494. immortal = {}
  495. for i,v in pairs(Character:GetDescendants()) do
  496.     if v:IsA("BasePart") and v.Name ~= "lmagic" and v.Name ~= "rmagic" then
  497.         if v ~= Root and v ~= Torso and v ~= Head and v ~= RightArm and v ~= LeftArm and v ~= RightLeg and v.Name ~= "lmagic" and v.Name ~= "rmagic" and v ~= LeftLeg then
  498.             v.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0)
  499.         end
  500.         table.insert(immortal,{v,v.Parent,v.Material,v.Color,v.Transparency})
  501.     elseif v:IsA("JointInstance") then
  502.         table.insert(immortal,{v,v.Parent,nil,nil,nil})
  503.     end
  504. end
  505. for e = 1, #immortal do
  506.     if immortal[e] ~= nil then
  507.         local STUFF = immortal[e]
  508.         local PART = STUFF[1]
  509.         local PARENT = STUFF[2]
  510.         local MATERIAL = STUFF[3]
  511.         local COLOR = STUFF[4]
  512.         local TRANSPARENCY = STUFF[5]
  513. if levitate then
  514.         if PART.ClassName == "Part" and PART ~= Root and PART.Name ~= eyo1 and PART.Name ~= eyo2 and PART.Name ~= "lmagic" and PART.Name ~= "rmagic" then
  515.             PART.Material = MATERIAL
  516.             PART.Color = COLOR
  517.             PART.Transparency = TRANSPARENCY
  518.         end
  519.         PART.AncestryChanged:connect(function()
  520.             PART.Parent = PARENT
  521.         end)
  522. else
  523.         if PART.ClassName == "Part" and PART ~= Root and PART.Name ~= "lmagic" and PART.Name ~= "rmagic" then
  524.             PART.Material = MATERIAL
  525.             PART.Color = COLOR
  526.             PART.Transparency = TRANSPARENCY
  527.         end
  528.         PART.AncestryChanged:connect(function()
  529.             PART.Parent = PARENT
  530.         end)
  531. end
  532.     end
  533. end
  534. function immortality()
  535.     for e = 1, #immortal do
  536.         if immortal[e] ~= nil then
  537.             local STUFF = immortal[e]
  538.             local PART = STUFF[1]
  539.             local PARENT = STUFF[2]
  540.             local MATERIAL = STUFF[3]
  541.             local COLOR = STUFF[4]
  542.             local TRANSPARENCY = STUFF[5]
  543.             if PART.ClassName == "Part" and PART == Root then
  544.                 PART.Material = MATERIAL
  545.                 PART.Color = COLOR
  546.                 PART.Transparency = TRANSPARENCY
  547.             end
  548.             if PART.Parent ~= PARENT then
  549.                 hum:Remove()
  550.                 PART.Parent = PARENT
  551.                 hum = Instance.new("Humanoid",Character)
  552.                                 hum.Name = "noneofurbusiness"
  553.             end
  554.         end
  555.     end
  556. end
  557. coroutine.wrap(function()
  558. while true do
  559. if hum.Health < .1 then
  560. deadsound = Instance.new("Sound", Torso)
  561. deadsound.Volume = 6
  562. deadsound.SoundId = "rbxassetid://1411352723"
  563. deadsound:Play()
  564. immortality()
  565. end
  566. wait()
  567. end
  568. end)()
  569.  
  570. local anims = coroutine.wrap(function()
  571. while true do
  572. settime = 0.05
  573. sine = sine + change
  574. if position == "Jump" and attacking == false then
  575. change = 1
  576. spin = false
  577. for i,v in pairs(Torso:GetChildren()) do if v:IsA("Sound") then v:Remove() end end
  578. LEFTLEGLERP.C1 = LEFTLEGLERP.C1:lerp(CFrame.new(0,0,0) * CFrame.Angles(0,0,0),.1)
  579. RIGHTLEGLERP.C1 = RIGHTLEGLERP.C1:lerp(CFrame.new(0,0,0) * CFrame.Angles(math.rad(0),0,0),.1)
  580. LEFTARMLERP.C1 = LEFTARMLERP.C1:lerp(CFrame.new(0,0,0) * CFrame.Angles(0,0,0),.4)
  581. ROOTLERP.C0 = ROOTLERP.C0:lerp(CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.2)
  582. LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(CFrame.new(1.4,.1,-.2) * CFrame.Angles(math.rad(20),math.rad(-3),math.rad(-4)), 0.2)
  583. RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(CFrame.new(-0.5, 2, 0) * CFrame.Angles(math.rad(10), math.rad(0), math.rad(0)), 0.2)
  584. LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(CFrame.new(0.5, 1.0, .9) * CFrame.Angles(math.rad(20), math.rad(0), math.rad(0)), 0.2)
  585. elseif position == "Falling" and attacking == false then
  586. change = 1
  587. spin = false
  588. for i,v in pairs(Torso:GetChildren()) do if v:IsA("Sound") then v:Remove() end end
  589. ROOTLERP.C0 = ROOTLERP.C0:lerp(CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(15), math.rad(0), math.rad(0)), 0.15)
  590. LEFTLEGLERP.C1 = LEFTLEGLERP.C1:lerp(CFrame.new(0,0,0) * CFrame.Angles(0,0,0),.1)
  591. RIGHTLEGLERP.C1 = RIGHTLEGLERP.C1:lerp(CFrame.new(0,0,0) * CFrame.Angles(math.rad(0),0,0),.1)
  592. LEFTARMLERP.C1 = LEFTARMLERP.C1:lerp(CFrame.new(0,0,0) * CFrame.Angles(0,0,0),.4)
  593. RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(CFrame.new(-0.5, 2, 0) * CFrame.Angles(math.rad(8), math.rad(4), math.rad(0)), 0.2)
  594. LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(CFrame.new(0.5, 2, 0) * CFrame.Angles(math.rad(8), math.rad(-4), math.rad(0)), 0.2)
  595. LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(CFrame.new(1.5,.94 + .02 * math.sin(sine/12),-0) * CFrame.Angles(math.rad(28 + 5 * math.sin(sine/12)),math.rad(0),math.rad(45)), 0.2)
  596. RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(CFrame.new(-1.5,.94 + .02 * math.sin(sine/12),-0) * CFrame.Angles(math.rad(28 + 5 * math.sin(sine/12)),math.rad(0),math.rad(-45)), 0.2)
  597. elseif position == "Walking" and attacking == false and running == false then
  598. change = 1.2
  599. walking = true
  600. spin = false
  601. for i,v in pairs(Torso:GetChildren()) do if v:IsA("Sound") then v:Remove() end end
  602. RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(CFrame.new(-1.5 + Root.RotVelocity.Y / 85,.35,-.5*math.sin(sine/11)) * CFrame.Angles(math.rad(35*math.sin(sine/11)),math.rad(0*math.sin(sine/11)),math.rad(-10 + Root.RotVelocity.Y / 10, math.sin(-20 * math.sin(sine/4)))),.3)
  603. LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(CFrame.new(1.5 + Root.RotVelocity.Y / 85,.45,.5*math.sin(sine/11)) * CFrame.Angles(math.rad(-55*math.sin(sine/11)),math.rad(-5*math.sin(sine/8)),math.rad(10 + Root.RotVelocity.Y / 10, math.sin(20 * math.sin(sine/4)))),.3)
  604. ROOTLERP.C0 = ROOTLERP.C0:lerp(CFrame.new(0, -.15 * 0.6*-math.sin(sine/5.5), 0) * CFrame.Angles(math.rad(10), math.rad(12 * -math.sin(sine/11)), math.rad(0) + Root.RotVelocity.Y / 30, math.cos(25 * math.cos(sine/10))), 0.3)
  605. RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(CFrame.new(-0.5, 1.92 - 0.35 * math.cos(sine/11)/2.8, -.2  + 0.2 - math.sin(sine/11)/3.4) * CFrame.Angles(math.rad(25 - 25) + -math.sin(sine/11)/2.3, math.rad(0)*math.cos(sine/1), math.rad(0), math.cos(-15 * 25 * math.cos(sine/11))), 0.3)
  606. LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(CFrame.new(0.5, 1.92 + 0.35 * math.cos(sine/11)/2.8, -.2 + 0.2 + math.sin(sine/11)/3.4) * CFrame.Angles(math.rad(25 - 25) - -math.sin(sine/11)/2.3, math.rad(0)*math.cos(sine/1), math.rad(0) , math.cos(-15 * 25 * math.cos(sine/11))), 0.3)
  607. elseif position == "Idle" and attacking == false and running == false then
  608. change = .5
  609. spin = true
  610. for i,v in pairs(Torso:GetChildren()) do if v:IsA("Sound") then v:Remove() end end
  611. ROOTLERP.C0 = ROOTLERP.C0:lerp(CFrame.new(0, -.2 + -.1 * math.sin(sine/12), 0) * CFrame.Angles(math.rad(6 * -math.sin(sine/12)),math.rad(0),math.rad(0)),.1)
  612. LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(CFrame.new(1.5,.27 + .02 * math.sin(sine/12),.20 * -math.sin(sine/12)) * CFrame.Angles(math.rad(20 * math.sin(sine/12)),math.rad(0),math.rad(10)), 0.1)
  613. RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(CFrame.new(-1.5,.27 + .02 * math.sin(sine/12),.20 * -math.sin(sine/12)) * CFrame.Angles(math.rad(20 * math.sin(sine/12)),math.rad(0),math.rad(-10)), 0.1)
  614. RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(CFrame.new(-0.3, 2 - .1 * math.sin(sine/12), 0) * CFrame.Angles(math.rad(6 * -math.sin(sine/12)), math.rad(0), math.rad(-10)), 0.1)
  615. LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(CFrame.new(0.3, 2.0 - .1 * math.sin(sine/12), 0) * CFrame.Angles(math.rad(6 * -math.sin(sine/12)), math.rad(0), math.rad(10)), 0.1)
  616. elseif position == "Running" and attacking == false then
  617. change = 1
  618. for i,v in pairs(Torso:GetChildren()) do if v:IsA("Sound") then v:Remove() end end
  619. RIGHTARMLERP.C0 = RIGHTARMLERP.C0:lerp(CFrame.new(0, .5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.3)
  620. LEFTARMLERP.C1 = LEFTARMLERP.C1:lerp(CFrame.new(-1.24+.6*math.sin(sine/4)/1.4, 0.54, 0-0.8*math.sin(sine/4))*CFrame.Angles(math.rad(6+140*math.sin(sine/4)/1.2), math.rad(0), math.rad(20+70*math.sin(sine/4))), 0.3)
  621. LEFTARMLERP.C0 = LEFTARMLERP.C0:lerp(CFrame.new(0,.5,0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  622. ROOTLERP.C0 = ROOTLERP.C0:lerp(CFrame.new(0, -.2, 0) * CFrame.Angles(math.rad(-20 - 0 * math.sin(sine/4)), math.rad(0 + 6 * math.sin(sine/4)), math.rad(0) + Root.RotVelocity.Y / 30, math.sin(10 * math.sin(sine/4))), 0.3)
  623. RIGHTLEGLERP.C1 = RIGHTLEGLERP.C1:lerp(CFrame.new(0,0,-.2 + .5*-math.sin(sine/4)),.3)
  624. RIGHTLEGLERP.C0 = RIGHTLEGLERP.C0:lerp(CFrame.new(-0.5, 1.6+0.1*math.sin(sine/4),.7*-math.sin(sine/4)) * CFrame.Angles(math.rad(15+ -50 * math.sin(sine/4)),0,0),.3)
  625. LEFTLEGLERP.C1 = LEFTLEGLERP.C1:lerp(CFrame.new(0,0,-.2 + .5*math.sin(sine/4)),.3)
  626. LEFTLEGLERP.C0 = LEFTLEGLERP.C0:lerp(CFrame.new(0.5, 1.6-0.1*math.sin(sine/4),.7*math.sin(sine/4)) * CFrame.Angles(math.rad(15 + 50 * math.sin(sine/4)),0,0),.3)
  627. end
  628. swait()
  629. end
  630. end)
  631. anims()
  632. warn("Classic Kirby V1 loaded! Made by youngmacka123.")
  633. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement