how to make a idle animation when equipping a tool

Опубликовано: 24 Май 2026
на канале: Plus257
37
0

first make a part, name the part "handle" then make a tool put the handle into the tool , put a local script in the tool put this script : local tool = script.Parent
local anim = Instance.new("Animation")
local anim1 = Instance.new("Animation")
anim.Name = "IdleAnim"
anim.AnimationId = "rbxassetid://anim id" -- Idle Animaton ID
anim1.Name = "EquipAnim"
anim1.AnimationId = "rbxassetid://anim id"-- Equip Tool Animaton ID
local track
local track1

tool.Equipped:Connect(function()
track = script.Parent.Parent.Humanoid:LoadAnimation(anim)
track1 = script.Parent.Parent.Humanoid:LoadAnimation(anim1)
track.Priority = Enum.AnimationPriority.Movement
track1.Priority = Enum.AnimationPriority.Movement
track.Looped = true
track:Play()
track1:Play()
end)


tool.Unequipped:Connect(function()
if track and track1 then
track:Stop()
track1:Stop()
end
end)
the part that says "anim id" is where you put your animation id for your idle animation and also please dont comment that this is a copy my acc got hacked and i will be making a video telling you how to do from the comments from my old video