local players = game.Players.LocalPlayer
local anim1 = script.Parent.Animation
local anim2 = script.Parent.FireAnimation
local anim = script.Parent.Rest
local track
local track2
local trackA
local UIS = game:GetService("UserInputService")
local CanFire = false
script.Parent.Equipped:Connect(function()
track = players.Character.Humanoid:LoadAnimation(anim1)
track:play()
end)
script.Parent.Unequipped:Connect(function()
trackA = players.Character.Humanoid:LoadAnimation(anim)
track:stop()
trackA:stop()
script.Parent.LocalScript.Disabled = false
end)
local debouce = false
script.Parent.Activated:Connect(function()
if debouce == false then
debouce = true
track2 = players.Character.Humanoid:LoadAnimation(anim2)
track2:play()
wait(.8)
debouce = false
end
end)
local Temp = false
local UIS = game:GetService("UserInputService")
local players = game.Players.LocalPlayer
local anim = script.Parent.Rest
local track
UIS.InputBegan:Connect(function(key)
if players.Character:FindFirstChild("M911") then
if key.KeyCode == Enum.KeyCode.E then
if Temp == false then
Temp = true
print("K")
trackA = players.Character.Humanoid:LoadAnimation(anim)
trackA:play()
elseif Temp == true then
Temp = false
trackA:stop()
end
end
end
end)
#Animation still plays after another one has played
1 messages · Page 1 of 1 (latest)
When you press E, plays a different animation
but when you active the weapon it plays a different one
im unsure of how to dix it
did you add animation priorities?
maybe the problem is the animations overlapping or interrupting each other
add checks before stopping the track
Worked
Thank you
np
hey, how to paste a script like this ?
I mean on discord
in this format
tysm