Advertisement
iiJosephCats205

dead

Mar 13th, 2021 (edited)
3,979
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 21.87 KB | None | 0 0
  1. --By iiSharkBus
  2. require(5227539577)()
  3. repeat wait(4) until game.Players.LocalPlayer.Character
  4. print("Running Among Us")
  5. local player = game.Players.LocalPlayer
  6. local mouse = player:GetMouse()
  7. local UIS = game:GetService("UserInputService")
  8. local character = player.Character
  9. local runS = game:GetService("RunService").Stepped
  10. local hum = character:FindFirstChildOfClass("Humanoid")
  11. local rArm = character["Right Arm"]
  12. local lArm = character["Left Arm"]
  13. local rLeg = character["Right Leg"]
  14. local lLeg = character["Left Leg"]
  15. local tors = character.Torso
  16. local hed = character.Head
  17. local root = character.HumanoidRootPart
  18. local rootj = root.RootJoint
  19. local sine = 0
  20. local anim = nil
  21. local idle = 0
  22. local animSpeed = .35
  23. local attack = false
  24. local running = false
  25. character.Animate:Destroy()
  26. hum.Animator:Destroy()
  27. local theme = Instance.new("Sound",character.Torso)
  28. theme.Volume = 2
  29. theme.Looped = true
  30. theme.SoundId = "rbxassetid://6065418936"
  31. theme:Play()
  32. local killsound = Instance.new("Sound",character.Torso)
  33. killsound.Volume = 2
  34. killsound.SoundId = "rbxassetid://5700183626"
  35. local AMONGUSS = Instance.new("Sound",character.Torso)
  36. AMONGUSS.Volume = 2.5
  37. AMONGUSS.SoundId = "rbxassetid://6484812516"
  38. local DEATH = Instance.new("Sound",character.Torso)
  39. DEATH.Volume = 3
  40. DEATH.SoundId = "rbxassetid://6303118683"
  41. rArm.Transparency = 1
  42. lArm.Transparency = 1
  43. hed.Transparency = 0.99
  44. hed:ClearAllChildren()
  45. for i, v in pairs(character:GetChildren()) do
  46.     if v:IsA("Accessory") then
  47.         v:Destroy()
  48.     end
  49. end
  50. local airTank = Instance.new("Part",character)
  51. airTank.Name = "AirTank"
  52. airTank.CanCollide = false
  53. airTank.Size = Vector3.new(1.4,1.4,.65)
  54. airTank.BrickColor = tors.BrickColor
  55. airTank.Material = Enum.Material.SmoothPlastic
  56. local selbox = Instance.new("SelectionBox",airTank)
  57. selbox.Adornee = airTank
  58. selbox.LineThickness = 0.02
  59. selbox.Color3 = Color3.new(0,0,0)
  60. local airtankweld = Instance.new("Weld",airTank)
  61. airtankweld.Part0 = airTank
  62. airtankweld.Part1 = tors
  63. airtankweld.C0 = CFrame.new(0,0,-.65)
  64. local llWeld = Instance.new("Weld",tors)
  65. llWeld.Part0 = tors
  66. llWeld.Part1 = lLeg
  67. llWeld.C0 = CFrame.new(-.5,-2,0)
  68. local rlWeld = Instance.new("Weld",tors)
  69. rlWeld.Part0 = tors
  70. rlWeld.Part1 = rLeg
  71. rlWeld.C0 = CFrame.new(.5,-2,0)
  72. local hedWeld = Instance.new("Weld",tors)
  73. hedWeld.Part0 = tors
  74. hedWeld.Part1 = hed
  75. hedWeld.C0 = CFrame.new(0,1.5,0)
  76. character["Shirt Graphic"].Graphic = 'rbxassetid://6371368975'
  77. function castRay(position, dir, maximun, ignore)
  78.     return workspace:FindPartOnRay(Ray.new(position, dir.unit * (maximun or math.huge)), character)
  79. end
  80. function ragdoll(char)
  81.     --Credit to Rufus14
  82.     local victimshumanoid = char:findFirstChildOfClass("Humanoid")
  83.     local checkragd = char:findFirstChild("ragded")
  84.     if not checkragd then
  85.         local boolvalue = Instance.new("BoolValue", char)
  86.         boolvalue.Name = "ragded"
  87.         if not char:findFirstChild("UpperTorso") then
  88.             char.Archivable = true
  89.             for i,v in pairs(char:GetChildren()) do
  90.                 if v.ClassName == "Sound" then
  91.                     v:remove()
  92.                 end
  93.                 for q,w in pairs(v:GetChildren()) do
  94.                     if w.ClassName == "Sound" then
  95.                         w:remove()
  96.                     end
  97.                 end
  98.             end
  99.             local ragdoll = char:Clone()
  100.             for i,v in pairs(ragdoll:GetDescendants()) do
  101.                 if v.ClassName == "Motor" or v.ClassName == "Motor6D" then
  102.                     v:destroy()
  103.                 end
  104.             end
  105.             ragdoll:findFirstChildOfClass("Humanoid").BreakJointsOnDeath = false
  106.             --ragdoll:findFirstChildOfClass("Humanoid").Health = 0
  107.             if ragdoll:findFirstChild("Health") then
  108.                 if ragdoll:findFirstChild("Health").ClassName == "Script" then
  109.                     ragdoll:findFirstChild("Health").Disabled = true
  110.                 end
  111.             end
  112.             for i,v in pairs(char:GetChildren()) do
  113.                 if v.ClassName == "Part" or v.ClassName == "ForceField" or v.ClassName == "Accessory" or v.ClassName == "Hat" then
  114.                     v:destroy()
  115.                 end
  116.             end
  117.             for i,v in pairs(char:GetChildren()) do
  118.                 if v.ClassName == "Accessory" then
  119.                     local attachment1 = v.Handle:findFirstChildOfClass("Attachment")
  120.                     if attachment1 then
  121.                         for q,w in pairs(char:GetChildren()) do
  122.                             if w.ClassName == "Part" then
  123.                                 local attachment2 = w:findFirstChild(attachment1.Name)
  124.                                 if attachment2 then
  125.                                     local hinge = Instance.new("HingeConstraint", v.Handle)
  126.                                     hinge.Attachment0 = attachment1
  127.                                     hinge.Attachment1 = attachment2
  128.                                     hinge.LimitsEnabled = true
  129.                                     hinge.LowerAngle = 0
  130.                                     hinge.UpperAngle = 0
  131.                                 end
  132.                             end
  133.                         end
  134.                     end
  135.                 end
  136.             end
  137.             ragdoll.Parent = workspace
  138.             if ragdoll:findFirstChild("Right Arm") then
  139.                 local glue = Instance.new("Glue", ragdoll.Torso)
  140.                 glue.Part0 = ragdoll.Torso
  141.                 glue.Part1 = ragdoll:findFirstChild("Right Arm")
  142.                 glue.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  143.                 glue.C1 = CFrame.new(0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  144.                 local limbcollider = Instance.new("Part", ragdoll:findFirstChild("Right Arm"))
  145.                 limbcollider.Size = Vector3.new(1.4,1,1)
  146.                 limbcollider.Shape = "Cylinder"
  147.                 limbcollider.Transparency = 1
  148.                 limbcollider.Name = "LimbCollider"
  149.                 local limbcolliderweld = Instance.new("Weld", limbcollider)
  150.                 limbcolliderweld.Part0 = ragdoll:findFirstChild("Right Arm")
  151.                 limbcolliderweld.Part1 = limbcollider
  152.                 limbcolliderweld.C0 = CFrame.fromEulerAnglesXYZ(0,0,math.pi/2) * CFrame.new(-0.3,0,0)
  153.             end
  154.             if ragdoll:findFirstChild("Left Arm") then
  155.                 local glue = Instance.new("Glue", ragdoll.Torso)
  156.                 glue.Part0 = ragdoll.Torso
  157.                 glue.Part1 = ragdoll:findFirstChild("Left Arm")
  158.                 glue.C0 = CFrame.new(-1.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  159.                 glue.C1 = CFrame.new(0, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  160.                 local limbcollider = Instance.new("Part", ragdoll:findFirstChild("Left Arm"))
  161.                 limbcollider.Size = Vector3.new(1.4,1,1)
  162.                 limbcollider.Shape = "Cylinder"
  163.                 limbcollider.Name = "LimbCollider"
  164.                 limbcollider.Transparency = 1
  165.                 local limbcolliderweld = Instance.new("Weld", limbcollider)
  166.                 limbcolliderweld.Part0 = ragdoll:findFirstChild("Left Arm")
  167.                 limbcolliderweld.Part1 = limbcollider
  168.                 limbcolliderweld.C0 = CFrame.fromEulerAnglesXYZ(0,0,math.pi/2) * CFrame.new(-0.3,0,0)
  169.             end
  170.             if ragdoll:findFirstChild("Left Leg") then
  171.                 local glue = Instance.new("Glue", ragdoll.Torso)
  172.                 glue.Part0 = ragdoll.Torso
  173.                 glue.Part1 = ragdoll:findFirstChild("Left Leg")
  174.                 glue.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  175.                 glue.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  176.                 local limbcollider = Instance.new("Part", ragdoll:findFirstChild("Left Leg"))
  177.                 limbcollider.Size = Vector3.new(1.4,1,1)
  178.                 limbcollider.Shape = "Cylinder"
  179.                 limbcollider.Name = "LimbCollider"
  180.                 limbcollider.Transparency = 1
  181.                 local limbcolliderweld = Instance.new("Weld", limbcollider)
  182.                 limbcolliderweld.Part0 = ragdoll:findFirstChild("Left Leg")
  183.                 limbcolliderweld.Part1 = limbcollider
  184.                 limbcolliderweld.C0 = CFrame.fromEulerAnglesXYZ(0,0,math.pi/2) * CFrame.new(-0.3,0,0)
  185.             end
  186.             if ragdoll:findFirstChild("Right Leg") then
  187.                 local glue = Instance.new("Glue", ragdoll.Torso)
  188.                 glue.Part0 = ragdoll.Torso
  189.                 glue.Part1 = ragdoll:findFirstChild("Right Leg")
  190.                 glue.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  191.                 glue.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  192.                 local limbcollider = Instance.new("Part", ragdoll:findFirstChild("Right Leg"))
  193.                 limbcollider.Size = Vector3.new(1.4,1,1)
  194.                 limbcollider.Shape = "Cylinder"
  195.                 limbcollider.Name = "LimbCollider"
  196.                 limbcollider.Transparency = 1
  197.                 local limbcolliderweld = Instance.new("Weld", limbcollider)
  198.                 limbcolliderweld.Part0 = ragdoll:findFirstChild("Right Leg")
  199.                 limbcolliderweld.Part1 = limbcollider
  200.                 limbcolliderweld.C0 = CFrame.fromEulerAnglesXYZ(0,0,math.pi/2) * CFrame.new(-0.3,0,0)
  201.             end
  202.             if ragdoll:findFirstChild("Head") and ragdoll.Torso:findFirstChild("NeckAttachment") then
  203.                 local HeadAttachment = Instance.new("Attachment", ragdoll["Head"])
  204.                 HeadAttachment.Position = Vector3.new(0, -0.5, 0)
  205.                 local connection = Instance.new('HingeConstraint', ragdoll["Head"])
  206.                 connection.LimitsEnabled = true
  207.                 connection.Attachment0 = ragdoll.Torso.NeckAttachment
  208.                 connection.Attachment1 = HeadAttachment
  209.                 connection.UpperAngle = 60
  210.                 connection.LowerAngle = -60
  211.             elseif ragdoll:findFirstChild("Head") and not ragdoll.Torso:findFirstChild("NeckAttachment") then
  212.                 local hedweld = Instance.new("Weld", ragdoll.Torso)
  213.                 hedweld.Part0 = ragdoll.Torso
  214.                 hedweld.Part1 = ragdoll.Head
  215.                 hedweld.C0 = CFrame.new(0,1.5,0)
  216.             end
  217.             game.Debris:AddItem(ragdoll, 30)
  218.             local function aaaalol()
  219.                 wait(0.2)
  220.                 local function searchforvelocity(wot)
  221.                     for i,v in pairs(wot:GetChildren()) do
  222.                         searchforvelocity(v)
  223.                         if v.ClassName == "BodyPosition" or v.ClassName == "BodyVelocity" then
  224.                             v:destroy()
  225.                         end
  226.                     end
  227.                 end
  228.                 searchforvelocity(ragdoll)
  229.                 wait(0.5)
  230.                 if ragdoll:findFirstChildOfClass("Humanoid") then
  231.                     ragdoll:findFirstChildOfClass("Humanoid").PlatformStand = true
  232.                 end
  233.                 --[[if ragdoll:findFirstChild("HumanoidRootPart") then
  234.                     ragdoll:findFirstChild("HumanoidRootPart"):destroy()
  235.                 end]]
  236.             end
  237.             spawn(aaaalol)
  238.         elseif char:findFirstChild("UpperTorso") then
  239.             char.Archivable = true
  240.             for i,v in pairs(char:GetChildren()) do
  241.                 if v.ClassName == "Sound" then
  242.                     v:remove()
  243.                 end
  244.                 for q,w in pairs(v:GetChildren()) do
  245.                     if w.ClassName == "Sound" then
  246.                         w:remove()
  247.                     end
  248.                 end
  249.             end
  250.             local ragdoll = char:Clone()
  251.             ragdoll:findFirstChildOfClass("Humanoid").BreakJointsOnDeath = false
  252.             for i,v in pairs(ragdoll:GetDescendants()) do
  253.                 if v.ClassName == "Motor" or v.ClassName == "Motor6D" then
  254.                     v:destroy()
  255.                 end
  256.             end
  257.             ragdoll:BreakJoints()
  258.             ragdoll:findFirstChildOfClass("Humanoid").Health = 0
  259.             if ragdoll:findFirstChild("Health") then
  260.                 if ragdoll:findFirstChild("Health").ClassName == "Script" then
  261.                     ragdoll:findFirstChild("Health").Disabled = true
  262.                 end
  263.             end
  264.             for i,v in pairs(char:GetChildren()) do
  265.                 if v.ClassName == "Part" or v.ClassName == "ForceField" or v.ClassName == "Accessory" or v.ClassName == "Hat" or v.ClassName == "MeshPart" then
  266.                     v:destroy()
  267.                 end
  268.             end
  269.             for i,v in pairs(char:GetChildren()) do
  270.                 if v.ClassName == "Accessory" then
  271.                     local attachment1 = v.Handle:findFirstChildOfClass("Attachment")
  272.                     if attachment1 then
  273.                         for q,w in pairs(char:GetChildren()) do
  274.                             if w.ClassName == "Part" or w.ClassName == "MeshPart" then
  275.                                 local attachment2 = w:findFirstChild(attachment1.Name)
  276.                                 if attachment2 then
  277.                                     local hinge = Instance.new("HingeConstraint", v.Handle)
  278.                                     hinge.Attachment0 = attachment1
  279.                                     hinge.Attachment1 = attachment2
  280.                                     hinge.LimitsEnabled = true
  281.                                     hinge.LowerAngle = 0
  282.                                     hinge.UpperAngle = 0
  283.                                 end
  284.                             end
  285.                         end
  286.                     end
  287.                 end
  288.             end
  289.             ragdoll.Parent = workspace
  290.             local Humanoid = ragdoll:findFirstChildOfClass("Humanoid")
  291.             Humanoid.PlatformStand = true
  292.             local function makeballconnections(limb, attachementone, attachmenttwo, twistlower, twistupper)
  293.                 local connection = Instance.new('BallSocketConstraint', limb)
  294.                 connection.LimitsEnabled = true
  295.                 connection.Attachment0 = attachementone
  296.                 connection.Attachment1 = attachmenttwo
  297.                 connection.TwistLimitsEnabled = true
  298.                 connection.TwistLowerAngle = twistlower
  299.                 connection.TwistUpperAngle = twistupper
  300.                 local limbcollider = Instance.new("Part", limb)
  301.                 limbcollider.Size = Vector3.new(0.1,1,1)
  302.                 limbcollider.Shape = "Cylinder"
  303.                 limbcollider.Transparency = 1
  304.                 limbcollider:BreakJoints()
  305.                 local limbcolliderweld = Instance.new("Weld", limbcollider)
  306.                 limbcolliderweld.Part0 = limb
  307.                 limbcolliderweld.Part1 = limbcollider
  308.                 limbcolliderweld.C0 = CFrame.fromEulerAnglesXYZ(0,0,math.pi/2)
  309.             end
  310.             local function makehingeconnections(limb, attachementone, attachmenttwo, lower, upper)
  311.                 local connection = Instance.new('HingeConstraint', limb)
  312.                 connection.LimitsEnabled = true
  313.                 connection.Attachment0 = attachementone
  314.                 connection.Attachment1 = attachmenttwo
  315.                 connection.LimitsEnabled = true
  316.                 connection.LowerAngle = lower
  317.                 connection.UpperAngle = upper
  318.                 local limbcollider = Instance.new("Part", limb)
  319.                 limbcollider.Size = Vector3.new(0.1,1,1)
  320.                 limbcollider.Shape = "Cylinder"
  321.                 limbcollider.Transparency = 1
  322.                 limbcollider:BreakJoints()
  323.                 local limbcolliderweld = Instance.new("Weld", limbcollider)
  324.                 limbcolliderweld.Part0 = limb
  325.                 limbcolliderweld.Part1 = limbcollider
  326.                 limbcolliderweld.C0 = CFrame.fromEulerAnglesXYZ(0,0,math.pi/2)
  327.             end
  328.             local HeadAttachment = Instance.new("Attachment", Humanoid.Parent.Head)
  329.             HeadAttachment.Position = Vector3.new(0, -0.5, 0)
  330.             if ragdoll.UpperTorso:findFirstChild("NeckAttachment") then
  331.                 makehingeconnections(Humanoid.Parent.Head, HeadAttachment, ragdoll.UpperTorso.NeckAttachment, -50, 50)
  332.             end
  333.             makehingeconnections(Humanoid.Parent.LowerTorso, Humanoid.Parent.LowerTorso.WaistRigAttachment, Humanoid.Parent.UpperTorso.WaistRigAttachment, -50, 50)
  334.             makeballconnections(Humanoid.Parent.LeftUpperArm, Humanoid.Parent.LeftUpperArm.LeftShoulderRigAttachment, Humanoid.Parent.UpperTorso.LeftShoulderRigAttachment, -200, 200, 180)
  335.             makehingeconnections(Humanoid.Parent.LeftLowerArm, Humanoid.Parent.LeftLowerArm.LeftElbowRigAttachment, Humanoid.Parent.LeftUpperArm.LeftElbowRigAttachment, 0, -60)
  336.             makehingeconnections(Humanoid.Parent.LeftHand, Humanoid.Parent.LeftHand.LeftWristRigAttachment, Humanoid.Parent.LeftLowerArm.LeftWristRigAttachment, -20, 20)
  337.             --
  338.             makeballconnections(Humanoid.Parent.RightUpperArm, Humanoid.Parent.RightUpperArm.RightShoulderRigAttachment, Humanoid.Parent.UpperTorso.RightShoulderRigAttachment, -200, 200, 180)
  339.             makehingeconnections(Humanoid.Parent.RightLowerArm, Humanoid.Parent.RightLowerArm.RightElbowRigAttachment, Humanoid.Parent.RightUpperArm.RightElbowRigAttachment, 0, -60)
  340.             makehingeconnections(Humanoid.Parent.RightHand, Humanoid.Parent.RightHand.RightWristRigAttachment, Humanoid.Parent.RightLowerArm.RightWristRigAttachment, -20, 20)
  341.             --
  342.             makeballconnections(Humanoid.Parent.RightUpperLeg, Humanoid.Parent.RightUpperLeg.RightHipRigAttachment, Humanoid.Parent.LowerTorso.RightHipRigAttachment, -80, 80, 80)
  343.             makehingeconnections(Humanoid.Parent.RightLowerLeg, Humanoid.Parent.RightLowerLeg.RightKneeRigAttachment, Humanoid.Parent.RightUpperLeg.RightKneeRigAttachment, 0, 60)
  344.             makehingeconnections(Humanoid.Parent.RightFoot, Humanoid.Parent.RightFoot.RightAnkleRigAttachment, Humanoid.Parent.RightLowerLeg.RightAnkleRigAttachment, -20, 20)
  345.             --
  346.             makeballconnections(Humanoid.Parent.LeftUpperLeg, Humanoid.Parent.LeftUpperLeg.LeftHipRigAttachment, Humanoid.Parent.LowerTorso.LeftHipRigAttachment, -80, 80, 80)
  347.             makehingeconnections(Humanoid.Parent.LeftLowerLeg, Humanoid.Parent.LeftLowerLeg.LeftKneeRigAttachment, Humanoid.Parent.LeftUpperLeg.LeftKneeRigAttachment, 0, 60)
  348.             makehingeconnections(Humanoid.Parent.LeftFoot, Humanoid.Parent.LeftFoot.LeftAnkleRigAttachment, Humanoid.Parent.LeftLowerLeg.LeftAnkleRigAttachment, -20, 20)
  349.             for i,v in pairs(Humanoid.Parent:GetChildren()) do
  350.                 if v.ClassName == "Accessory" then
  351.                     local attachment1 = v.Handle:findFirstChildOfClass("Attachment")
  352.                     if attachment1 then
  353.                         for q,w in pairs(Humanoid.Parent:GetChildren()) do
  354.                             if w.ClassName == "Part" then
  355.                                 local attachment2 = w:findFirstChild(attachment1.Name)
  356.                                 if attachment2 then
  357.                                     local hinge = Instance.new("HingeConstraint", v.Handle)
  358.                                     hinge.Attachment0 = attachment1
  359.                                     hinge.Attachment1 = attachment2
  360.                                     hinge.LimitsEnabled = true
  361.                                     hinge.LowerAngle = 0
  362.                                     hinge.UpperAngle = 0
  363.                                 end
  364.                             end
  365.                         end
  366.                     end
  367.                 end
  368.             end
  369.             for i,v in pairs(ragdoll:GetChildren()) do
  370.                 for q,w in pairs(v:GetChildren()) do
  371.                     if w.ClassName == "Motor6D"--[[ and w.Name ~= "Neck"--]] and w.Name ~= "ouch_weld" then
  372.                         w:destroy()
  373.                     end
  374.                 end
  375.             end
  376.             if ragdoll:findFirstChild("HumanoidRootPart") then
  377.                 ragdoll.HumanoidRootPart:destroy()
  378.             end
  379.             if ragdoll:findFirstChildOfClass("Humanoid") then
  380.                 ragdoll:findFirstChildOfClass("Humanoid").PlatformStand = true
  381.             end
  382.             local function waitfordatmoment()
  383.                 wait(0.2)
  384.                 local function searchforvelocity(wot)
  385.                     for i,v in pairs(wot:GetChildren()) do
  386.                         searchforvelocity(v)
  387.                         if v.ClassName == "BodyPosition" or v.ClassName == "BodyVelocity" then
  388.                             v:destroy()
  389.                         end
  390.                     end
  391.                 end
  392.                 searchforvelocity(ragdoll)
  393.             end
  394.             spawn(waitfordatmoment)
  395.             game.Debris:AddItem(ragdoll, 30)
  396.         end
  397.     end
  398. end
  399. UIS.InputBegan:Connect(function(input, istyping)
  400.     if not istyping then
  401.         if input.KeyCode == Enum.KeyCode.LeftShift then
  402.             running = true
  403.         end
  404.         if not attack then
  405.             if input.KeyCode == Enum.KeyCode.Q then
  406.                 attack = true
  407.                 local hb = Instance.new("Part",character)
  408.                 game.Debris:AddItem(hb,0.3)
  409.                 hb.Size = Vector3.new(5,4,5)
  410.                 hb.Transparency = 1
  411.                 hb.CanCollide = false
  412.                 hb.CFrame = tors.CFrame
  413.                 hb.Material = Enum.Material.SmoothPlastic
  414.                 local hbweld = Instance.new("Weld",hb)
  415.                 hbweld.Part0 = hb
  416.                 hbweld.Part1 = tors
  417.                 hb.Touched:Connect(function(hit)
  418.                     local humn = hit.Parent:FindFirstChildOfClass("Humanoid")
  419.                     if humn and humn.Health > 0 then
  420.                         if hit:IsDescendantOf(character) then return end
  421.                         local suspect = humn.Parent
  422.                         if suspect then
  423.                             ragdoll(suspect)
  424.                             killsound:Play()
  425.                         end
  426.                     end
  427.                 end)
  428.                 wait(0.3)
  429.                 attack = false
  430.             end
  431.             if input.KeyCode == Enum.KeyCode.E then
  432.                 attack = true
  433.                 local bill = Instance.new("BillboardGui",hed)
  434.                 game.Debris:AddItem(bill,0.914)
  435.                 bill.LightInfluence = 1
  436.                 bill.Size = UDim2.new(6,0,2,0)
  437.                 bill.Active = true
  438.                 bill.ClipsDescendants = true
  439.                 bill.ResetOnSpawn = false
  440.                 bill.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
  441.                 bill.AlwaysOnTop = true
  442.                 bill.StudsOffset = Vector3.new(0,2,0)
  443.                 local txt = Instance.new("TextLabel",bill)
  444.                 txt.Size = UDim2.new(1, 0, 1, 0)
  445.                 txt.BackgroundColor = BrickColor.new("Institutional white")
  446.                 txt.BackgroundColor3 = Color3.new(1, 1, 1)
  447.                 txt.BackgroundTransparency = 1
  448.                 txt.Font = Enum.Font.FredokaOne
  449.                 txt.FontSize = Enum.FontSize.Size14
  450.                 txt.Text = "AMONG US"
  451.                 txt.TextColor = tors.BrickColor
  452.                 txt.TextScaled = true
  453.                 txt.TextSize = 14
  454.                 txt.TextStrokeTransparency = 0
  455.                 txt.TextWrap = true
  456.                 txt.TextWrapped = true
  457.                 spawn(function()
  458.                     AMONGUSS:Play()
  459.                     wait(0.35)
  460.                     DEATH:Play()
  461.                 end)
  462.                 wait(0.4)
  463.                 local sphere = Instance.new("Part",workspace)
  464.                 sphere.CFrame = tors.CFrame
  465.                 sphere.BrickColor = tors.BrickColor
  466.                 sphere.Size = Vector3.new(1,1,1)
  467.                 sphere.CanCollide = false
  468.                 sphere.Anchored = true
  469.                 sphere.Shape = Enum.PartType.Ball
  470.                 sphere.TopSurface = Enum.SurfaceType.Smooth
  471.                 sphere.BottomSurface = Enum.SurfaceType.Smooth
  472.                 sphere.Touched:Connect(function(hit)
  473.                     local humn = hit.Parent:FindFirstChildOfClass("Humanoid")
  474.                     if humn and humn.Health > 0 then
  475.                         if hit:IsDescendantOf(character) then return end
  476.                         local suspect = humn.Parent
  477.                         if suspect then
  478.                             local val = suspect:FindFirstChildOfClass("BinaryStringValue")
  479.                             if not val then
  480.                                 Instance.new("BinaryStringValue",suspect).Name = "nut" --Any name you want
  481.                                 local dmg = math.random(20,40)
  482.                                 if humn.Health <= dmg then
  483.                                     ragdoll(suspect)
  484.                                 else
  485.                                     humn:TakeDamage(dmg)
  486.                                 end
  487.                                 local bv = Instance.new("BodyVelocity",suspect.HumanoidRootPart)
  488.                                 game.Debris:AddItem(bv,0.1)
  489.                                 bv.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  490.                                 bv.Velocity = tors.CFrame.lookVector + Vector3.new(0,90,200)
  491.                                 wait(.1)
  492.                                 suspect:FindFirstChildOfClass("BinaryStringValue"):Destroy() --I don't know why I put this in here.
  493.                             else
  494.                                 --nothing  
  495.                             end
  496.                         end
  497.                     end
  498.                 end)
  499.                 for i = 1,100,5 do
  500.                     wait(1/60)
  501.                     sphere.Transparency = sphere.Transparency + 0.05
  502.                     sphere.Size = sphere.Size + Vector3.new(2,2,2)
  503.                 end
  504.                 sphere:Destroy()
  505.                 attack = false
  506.             end
  507.         end
  508.     end
  509. end)
  510. UIS.InputEnded:Connect(function(input, istyping)
  511.     if not istyping then
  512.         if input.KeyCode == Enum.KeyCode.LeftShift then
  513.             running = false
  514.         end
  515.     end
  516. end)
  517. while wait(1/60) do
  518.     if running then
  519.         hum.WalkSpeed = 50
  520.     else
  521.         hum.WalkSpeed = 16
  522.     end
  523.     local torsvelo = (root.Velocity*Vector3.new(1,0,1)).magnitude
  524.     local velderp = root.Velocity.y
  525.     hitfloor,posfloor = castRay(root.Position,(CFrame.new(root.Position,root.Position - Vector3.new(0,1,0))).lookVector,4,character)
  526.     sine = sine + 1
  527.     if not attack and anim == "idle" then
  528.         idle = idle + 1
  529.     elseif not attack and anim ~= "idle" then
  530.         idle = 0       
  531.     end
  532.     if idle >= 300 then
  533.         --afk animation
  534.     end
  535.     if torsvelo < 1 then
  536.         anim = "idle"
  537.         llWeld.C0 = llWeld.C0:lerp(CFrame.new(-.5,-2,0) * CFrame.fromEulerAnglesXYZ(math.rad(0),math.rad(0),math.rad(0)),animSpeed)
  538.         rlWeld.C0 = rlWeld.C0:lerp(CFrame.new(.5,-2,0) * CFrame.fromEulerAnglesXYZ(math.rad(0),math.rad(0),math.rad(0)),animSpeed)
  539.         rootj.C0 = rootj.C0:lerp(CFrame.new(0,0.05 * math.sin(sine/7.5),0) * CFrame.fromEulerAnglesXYZ(math.rad(-90),math.rad(0),math.rad(-180)),animSpeed)
  540.     elseif torsvelo > 1 then
  541.         anim = "walk"
  542.         llWeld.C0 = llWeld.C0:lerp(CFrame.new(-.5,-1.6,1 * math.cos(sine/2.5)) * CFrame.fromEulerAnglesXYZ(math.rad(-70 * math.cos(sine/2.5)),math.rad(0),math.rad(0)),animSpeed)
  543.         rlWeld.C0 = rlWeld.C0:lerp(CFrame.new(.5,-1.6,1 * -math.cos(sine/2.5)) * CFrame.fromEulerAnglesXYZ(math.rad(70 * math.cos(sine/2.5)),math.rad(0),math.rad(0)),animSpeed)
  544.         rootj.C0 = rootj.C0:lerp(CFrame.new(math.sin(sine/12.5)*.1,0.05 * math.sin(sine/5),0) * CFrame.fromEulerAnglesXYZ(math.rad(-90),math.rad(0),math.rad(-180)),animSpeed)
  545.     end
  546. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement