How to properly animate a tool's model (don't use humanoid)

I’m posting this because i couldn’t find the answer to it anywhere on the dev forum.
Basically i had been trying to animate a tool to make a gun’s slide move back. To do this i used a humanoid to animate the model which caused some problems with the default player movement. The player’s movement and rotate speed would be dramatically slowed.

This first video is of a normal player’s rotation and jump.


player rotates relatively fast and can jump about 10 or so studs.

Now with the tool which has a humanoid.
First the rotation:


Noticable difference in speed although it can be inconsistent speeding up and slowing down. And yes im sure its studio and not me clicking too fast.

Now the jump


The jump distance is only 8 studs now. The change in jump distance is much more consistent than the slowed rotate speed.

Before anyone asks i am 100% sure this is the humanoid’s fault. No other scripts are running besides the default roblox ones. All baseparts in the model have canCollide set to false, massless set to true, and density set as low as possible.

To properly animate a tool

  1. make sure all baseparts are massless
  2. turn collisions off for parts that dont need to collide
  3. use an Animator.
    An animator does the same thing as a humanoid in regards to animating but without all the other physics stuff that comes with humanoids. It’s the same method too. Animator:LoadFunction(animation).

p.s. Ignore the drawings on the video, they are just so i can protect the identity of my private alt and the place.

3 Likes

TL:DR use an animator instead of a humanoid.

3 Likes

AnimationController would also have been appropriate but it’s been deprecated should be used for animating non-Humanoid models. Animator AnimationController should be used when you want to work with non-Humanoid model animations. Animator mainly is for animation playback control and replication. Animator is used for both, so you’re actually looking to use an AnimationController.

An update some time ago deprecated Humanoid animation functions as well as AnimationController and you’re encouraged, for newer projects, to directly access or create an Animator object. You can also manage the Animator object yourself if you want to control animation playback replication.

1 Like

i believe you need an AnimationController to put an Animator inside of.

1 Like

Whoops! Thank you for the correction, I was wrong there. It’s only LoadAnimation that’s deprecated on both the Humanoid and AnimationController, the instance itself isn’t. AnimationController is still good to be used for non-Humanoid entities then.

Updated my response. You should use AnimationController for non-Humanoid objects.

1 Like