How to animate tools (the easiest and best way) (for melees)

I’ve been having a similar issue. I’ve tried following a couple different methods and the same thing has happened, so I’m not sure what’s happening.

1 Like

No this method still works perfectly fine. Show a video or the script and I could maybe fix it for you.

@That0nePixel

1 Like

can i use the default roblox animator to do this?

1 Like

The default animator seems to be iffy about recognizing the tool parented to the rig, but you could probably get it working if you tried.

How would I make a tool holstering system? Like, how would I clone the model and weld it to the lower part of the player’s torso, is that possible with this system? I’m kinda new to this so I don’t know how i’d go about this.

This might work but would be a weird way to do it if you want it to be permanent I’d say just make a clone of the holster and have it be welded on to the player. Welding model to character - #4 by S0MBRX This is a easy way to do so if you just add a couple things. This is also really late but idc.

3 Likes

Thanks for this post. I was confused as to why the “Handle” keyframes in my animations didn’t replicate when I equipped it as an actual player in game. I didn’t know that the “RightGrip” weld only attaches two points together (namely the weapon handle and the arm) without taking into account animation keyframes.

Although:

local a:Weld = char:FindFirstChild("Right Arm"):WaitForChild("Right Grip")

This didn’t work for me. I’m not sure why you did that. Instead, I just referenced them separately using parameters:

tool.Equipped:Connect(function(used, character, animator, rightArm)
	character = script.Parent.Parent
	animator = character:FindFirstChild("Humanoid"):FindFirstChild("Animator")
	rightArm = character:FindFirstChild("Right Arm")
	rightGrip = rightArm:WaitForChild("RightGrip")
        -- etc.
end)

That was what worked for me. Not entirely sure as to why your variable in particular wasn’t working, I am relatively new to scripting, and the only difference I can see is that your “char” is outside of the event handler and mine isn’t.

4 Likes

It didn’t recognise rightGrip on this script either.

There’s a whole host of reasons why that would be the case. This method/script is working. But without further context and details with regard to how you personally tried to implement it, I can’t help you.

It was actually a dumb mistake, I was using R15, so I had to change “Right Arm” to “RightHand”

if you spend time animating the actual sword and then you have some other swords with different names, will they also be animated? i used a different method of achieving the animating of the tools but the only issue is, i have to reanimate every single tool in the game. got any solutions?

I’m having an issue where the right grip attachment doesn’t generate, even though it appears every time I give the tool to a dummy. Do any of you have any idea what I could be doing wrong?
Images of stuff relating to my sword model and workspace should be below



Forgot to put in the last image

1 Like

Rename “RightGripAttachment” to “RightGrip”

It’s an attachment instead of being a weld so the script runs into errors if I do that.
Also, its part of the character when it spawns in so I can’t edit it easily.

Never mind, the issue resolved itself after I restarted my computer :/.

I’ve been trying to figure out how to use this with my custom hotbar,

basically, when you press 1, it plays the animation to unsheathe the sword, then equips it during the animation (after the hand makes contact with the sheath),

but the issue is, that the Right Grip weld gets created and added under Right Arm anytime you equip something, is there anyway to stop that? Also since the animation works with the motor6d, and im trying to add it before the animation but also before the equip, i think it causes some problems.

Whats the best way to fix this? making the weapon transparent by default, then visible during the unsheathe keyframe of the animation?

Edit: I’m going to try the transparency thing, i just think there must be a better way to do it

i just wanted to thank you for making this, i literally have this bookmarked on my start page to use every time i make a tool

This is the closest solution to my porblem that ive had for weeks at this point.
Im trying to make the sword do a floaty animation next to the hand, ive replaced the rightGrip with motor6d but it still wont play
Anyone know why?

Not enough context but I assume animating it works but playing it in game doesnt?

If so make sure you have a ServerScript (not a local script) under the tool that has this code in it:

and make sure you create a variable called “char” at the top of the script which is set to the character model of the player who has the tool.

2 Likes