I looked up how to play an animation and did the same code but it didn't work. There are no errors. Any help on what I am doing wrong is appreciated. Animation ID - rbxassetid://3408083014
local animation = script.Parent.Parent.Animation script.Parent.Parent.Activated:Connect(function() local plr = game.Players:WaitForChild(script.Parent.Parent.Parent.Name) local char = plr.Character local humanoid = char.Humanoid local track = humanoid:LoadAnimation(animation) print('Play') track:Play() print('Done') end)
This should work, just change up the parent's and stuff like that
wait(0.2) local animation = script.Parent.Parent.Parent.Animation script.Parent.Activated:Connect(function() wait(0.1) local plr = game.Players.LocalPlayer print(plr) local hum = plr.Character.Humanoid local track = hum:LoadAnimation(animation) track:Play() end)