So im trying to make the player punch by pressing z but i keep getting this error
Animation "http://www.roblox.com/asset/?id=http://www.roblox.com/asset765720015&serverplaceid=0" failed to load in "Animation.AnimationId": Animation failed to load
so I'm unsure what i can do to fix it i've tried using other peoples animation on key codes but they don't seem to work either.
local player = game.Players.LocalPlayer
repeat wait() until player.Character.Humanoid
local humanoid = player.Character.Humanoid
local mouse = player:GetMouse()
local anim = Instance.new("Animation")
anim.AnimationId = "http://www.roblox.com/asset765720015" -- id of animation
mouse.KeyDown:connect(function(key)
if key == "z" then
local playAnim = humanoid:LoadAnimation(anim)
playAnim:Play()
end
end)

1 comment
That is not a valid animation id.