I am trying to play an animation with a tool whenever that tool has been activated. When I try, my animation never plays.
local plr = game:GetService("Players").LocalPlayer local char = plr.Character or plr.CharacterAdded:Wait() local h = char:WaitForChild("Humanoid") local anim = h:LoadAnimation(script.Parent:WaitForChild("Animation")) script.Parent.Activated:connect(function() anim:Play() end)
This code is Local Script in a tool in the starter pack The animation is a child of the tool and has an ID The animation is 1 second long The animations priority is set to [Action]