Tool = script.Parent local player = game.Players.LocalPlayer repeat wait() until player.Character ~= nil local hum = player.Character:WaitForChild("Humanoid") local animation = script.Parent.ExportAnim --Change DanceAnim to the name of your animation. local AnimTrack = hum:LoadAnimation(animation) --Loads the animation into the humanoid. Tool.Activated:connect(function(mouse) --If you're using a tool, change Selected to Activated, and get rid of the code on the next line. Otherwise, keep this the same. AnimTrack:Play() end) end) Tool.Unequipped:connect(function() --If you're using a tool, change Deselected to Unequipped. Otherwise keep it the same. AnimTrack:Stop() end)
I want to make a bomb so that when you use it it throws it with an animation, this is what I havebut its not working?