"Animation failed to load" error

Could it be made into so when you press it again it stops so when you press it, it starts and when you press it again it stops instead of so when you move it stops?

I will try to but i may not be able to

Maybe try replacing “wait(20)” and type this in "UIS.InputBegan:Connect(function(key, gp)
if key.KeyCode == animation then
local anim = plr.Character.Humanoid:LoadAnimation(script.Anims.animation)
anim:Stop() "

But i don’t know if i will work