Animating Accessories w/o Humanoid or AnimationController

I need to animate a model that is attached to a character as an accessory.

I searched the DevForum for answers and found two posts by @MapleMarvel, the first one being problems with AnimationControllers not replicating to other clients and the second being how to run animations without Humanoids or AnimationControllers.

The second post was solved by @Wunder_Wulfe, he suggested that:

Is there a simpler way of animating accessories? If not, how would I go about implementing @Wunder_Wulfe’s suggestion (with no experience using CFrames or Custom Rigs)?

2 Likes

Simple answer; you don’t.

Either you can take the long route and create a custom animation system that utilises the CFrame properties of JointInstances, or you can use an animation editing plugin and create an animation using Humanoids or AnimationControllers (which in itself requires Motor6Ds, a class that inherits from JointInstances and operates using CFrames).

Without a custom implementation or animation objects, you can’t “animate” accessories.

You can still animate models welded to characters using animation plugins, just saying.

1 Like

How would I weld an item to a character without using accessories?

The most common way is to have a weld part, which serves as the root (or PrimaryPart) of the model. This weld part is an invisible copy of a character limb which you intend to weld something to. All your parts should be welded to this weld part and the weld part should be welded to the limb in question. The model should be a descendant of the character.

How would I weld the model on characterAdded?

The Scripting Support category is not a venue to ask for code so I can’t provide you any implementations, though I can offer you advice as to where to go - which you’ve pretty much answered for yourself. In any standard environment where you’d usually weld a model to a character, just incorporate that into your CharacterAdded event.

  • Connect to CharacterAdded
  • Clone the pre-welded model (if you don’t need the model modified at run time, you should always strive to pre-weld objects rather than do so at run time via weld scripts)
  • Parent the cloned item as a child to the character
  • Weld the WeldPart to the limb you want the accessory attached to
  • Set the NetworkOwnership of any BasePart descendants to the client via Model.GetDescendants (I often forget network ownership myself, though now with experimental mode gone, network ownership sets are important)

To put it into perspective, I’ve come up with a quick repro in Studio that demonstrates the object hierarchy and such. Have a look.

Studio Breakdown (JointInstances unincluded):

How it should appear at run time:

5 Likes

How does network ownership work? Also could you give me this file?

All unanchored parts are physically simulated on Roblox. Network ownership pertains to which environment is responsible for calculating physics; the server or the client. To minimise the server workload and allow for immediate client feedback, you would normally assign the client as the network owner of a part and therefore the one calculating its physics. Characters are network owned by the client which is why you’ll notice that there’s no delays when you’re moving around.

More information: Network Ownership


I’m not quite sure what you can do with my place file since it’s merely a visual demonstration of how the assembly should appear, but I can provide it to you if you’re able to salvage it or use it as a guideline for your own use cases, I suppose.

WeldVisualAssembly.rbxl (51.2 KB)

2 Likes

Thanks!

May I ask, are you able to link a few of these animation plugins that work on models welded to a StarterCharacter?

You could just search them up yourself if you had a quick moment, you would’ve been able to find them quicker than necrobumping and waiting a few hours for a reply.

Moon Animator is a personal favourite of mine and a lot of other animators, whether making animations in the suite itself or cleaning up animations imported from Blender.

Do you have any plugins that can be used to achieve this? Is extra scripting required to accomplish this?

I have a model that gets welded to the player’s hand and need to make it so that I can animate it. It’s a sword and I’m trying to animate a throw mechanic, and im not sure if I should replace the weld with a Motor6D

If you want to be able to animate parts using Roblox animations, you will need to use Motor6Ds. If not, then you’d have to write your own code to handle movement or anything else you want.

Ever since figuring out the formula for welding (I don’t really understand it myself but I’ve memorised it), I don’t use plugins for any welding, only for animating. I’m not sure which part specifically you were looking for a plugin on, but if it’s welding then yeah I do that myself via the command bar nowadays.

What would I do if I say had a model welded to a player that I wanted to animate independently of the character. Would I use Motor6D’s?

If you’re using animations then yes, you still do. Animations rely on manipulating the Transform property of Motor6Ds in order to make things work. That being said, if you’re using Roblox animations then your model also needs an AnimationController in order to load the animation for the model and that’s out of the scope of the original thread which is about animating models without Roblox animations. You should create a new thread if you have a different problem you want to try resolving.

1 Like

There’s an hacky way to do this, I personally animated a SkinnedMesh through the use of Motor6D to the head or the mesh with an AnimationController, then converted it into an accessory live in game, which still played the animation flawlessly (through the accessory object attached to an Humanoid).
Roblox seems to be play animations with a very rigid instance based method that ignores such things, good for us.

Which means this is 100% possible but surely unintended, which is a shame considering the potential is great.