I been trying to make it so that when a player equips a tool, a animation plays.
This is what if have so far, when I test it, nothing happens. Can anybody help figure what went wrong and why the animation wont play when the tool is equipped?
local FightTool = game.StarterPack.Fight local function onEquip() local thePlayer = game.Players.LocalPlayer local animation = game.StarterPack.Fight.LocalScript.Animation.AnimationId local humanoid = thePlayer.Character.Humanoid local animationn = Instance.new("Animation") animationn.AnimationId = animation local PlayAnimation = humanoid:LoadAnimation(animationn) PlayAnimation:Play() end FightTool.Equipped:Connect(onEquip)