Weapon Weld Equip/Unequip Animation

Hey Devforum! I’m trying to figure out the steps on how to make a equip, and unequip animation for weapons, and welding the weapon to the body parts. That’s why I’m here to to ask you guys how you would approach it, to learn and find the most efficient way to do so.

The best way to do a equip/unequip animation is to add a local script in the weapon (tool).

Tools have equipped and unequipped events, so you can have the animations by receiving those events. Roblox advises you to use
Humanoid.Animator:LoadAnimation(anim)
But in my opinion
Humanoid:LoadAnimation(anim)
Is also the same.

As for welding, if it is a tool, when equipped it will be welded automatically.

1 Like

It is deprecated, the best to use right now is Humanoid.Animator:LoadAnimation(anim)

You can use .Equipped and .Unequipped events to make that work.

for equipping animation:

local EquipAnim = Humanoid.Animator:LoadAnimation(equipAnim)
Tool.Equipped:Connect(function()
    EquipAnim:Play()
end)

for unequipping animation:

local UnequipAnim = Humanoid.Animator:LoadAnimation(unequipAnim)
Tool.Unequipped:Connect(function()
    UnequipAnim:Play()
end)

I know it already welds when equipping a tool, but like I use Motor6D.

Sure that works but what about UIS(UserInputService), because that’s what I’m using currently, but I do agree with how you would do it with a tool

You can use a variable probably and set it to true when equipped and to false when unequipped and detect the mouse clicking and check if the variable is true and proceed:

local Equipped = false
Tool.Equipped:Connect(function()
    Equipped = true
end)
Tool.Unequipped:Connect(function()
    Equipped = false
end)

-- Your UIS stuff here, check if Equipped is true when inputbegan with mouse click