The animations keep playing even after its ended/stopped. Randomly
Does this only happen to NPCs?
if status.HyperArmour.Value == true then
local rps = math.random(8,11) / 10
local ps = Sounds.Punched.BlockedPunch:Clone()
ps.Parent = character.HumanoidRootPart
ps.PlaybackSpeed = rps
ps:Play()
delay(ps.TimeLength + 1, function()
ps:Destroy()
end)
--Damage
humanoid:TakeDamage(config.Damage / 4)
else
hitgrabbed = true
Whiff = false
Values.Status.IFrames.Value = true
status.Grabbed.Value = true
status.BlockBypassed.Value = true
local HitAnim = humanoid:LoadAnimation(Animation)
HitAnim:Play()
local c = Sounds.Impact.Grab:Clone()
c.Parent = character["Torso"]
c:Play()
delay(c.TimeLength + 1, function()
c:Destroy()
end)
humanoid.WalkSpeed = 0
hum.WalkSpeed = 0
local children = character:GetChildren()
for i,v in pairs(children) do
if children[i]:IsA("Part") then
children[i].Massless = true
end
end
local Weld = Instance.new("Motor6D", hroot)
Weld.Part0 = hroot
Weld.Part1 = character.HumanoidRootPart
Weld.C0 *= CFrame.new(0,0,-2)*CFrame.Angles(0,math.rad(180),0)
Animations.Grab2:Play()
local function Grabbed2()
Weld:Destroy()
HitAnim:Stop()
Values.Status.IFrames.Value = false
for i,v in pairs(children) do
if children[i]:IsA("Part") then
children[i].Massless = false
end
end
--Damage/Sound
local c = Sounds.Impact.BloodImpact:Clone()
c.Parent = character["Head"]
c:Play()
delay(c.TimeLength + 1, function()
c:Destroy()
end)
humanoid:TakeDamage(config.Damage)
--Knockback
humanoid.WalkSpeed = character.Values.WalkSpeed.Value
local target = humanoid.Parent.HumanoidRootPart
local BV = Instance.new("BodyVelocity")
local BV1 = Instance.new("BodyVelocity")
BV.P = 1e5
BV.MaxForce = Vector3.new(1e5, 1e5, 1e5)
BV.Velocity = hroot.CFrame.LookVector * (config.Knockback)
BV.Parent = target
character.Values.Status.Ragdolled.RagdollTime.Value = config.Ragdoll
character.Values.Status.Ragdolled.Value = true
game.Debris:AddItem(BV, .1)
status.Grabbed.Value = false
hitgrabbed = false
end