Creating first person arms and weapons: To merge or not to merge?

Hey everyone! I have a question when it comes to integrating the first person arms and weaponry into a game project I am working on!

So theoretically, I have my first person mesh fully rigged and animated and ready for export into the unreal engine. I also have my weapons rigged and animated as well. I have the weapons on their own rig, and the arms with their own rig as well. What I would have to do is have each rig have their own animations, that pair up with each other. So what I would do is, for example, when I activate the reload animation, I would need to select the same animation for both rigs. The hands would do the motions of taking out the magazine and put a new one in. The gun rig would have the magazine float out, and have a new clip float in, if previewed by themselves. When you play both animations together, it syncs up and looks like it should.

However, using this ‘dual’ animation setup I can see potential bugs in the future where the animations wouldn’t sync up, one of the skeletal meshes wouldn’t load, things like that. I was thinking, if I just merged the rigs together so both the arms and the gun would be one skeletal mesh, I would be skipping all those problems that I could come across in the future. Would this be the way to go? How is this done on a professional level? Say, a game like half life, do they just have the rigs merged, or not?

If you don’t need to change the clothes of your character (or change your character – like picking a kind of character,) then building the arms into the weapons is fine.
If you have character customization of any kind, it’s likely better to keep them separate.
(Well, if all you do for customization is a texture swap, then you could probably still keep the arms integrated.)

If you have multiple weapons, this can get complicated. I prefer separate weapons, but that is my preference.

if you have more than a few weapons then i would keep them separate, you can look at the shooter demo as an example on how its done.

A common approach(and the one used in the shooter example) is to use a single animated rig for the arms and then use sockets for the gun and ammo clips

Our project has 6 pieces of equipment, FYI

Last week’s Fortnite animation stream had an interesting explanation of how they set up their character rigs to work with different weapon types, different character sizes, etc. Being a third person game, it’s obviously more complicated than a first person game would be, but it might give you some insight into what’s possible.

Personally, I would absolutely not animate the weapons. What you describe (reloading a weapon, changing the clip, etc.) could be handled with static meshes and attachment sockets.

If you really must animate the weapon, then having both character and weapon animations start at the same time will prevent any issues, provided they’re in the same length, etc. There’s no such thing as animations “not syncing up”, they all advance using the same delta time.

SetMasterPoseComponent is how you’d go about it. Have one master skeletal mesh drive the animation (best to have this on the weapon mesh) then attach your child mesh and use SetMasterPoseComponent (which would be the hands). The hand bones would be present but not be visible on the weapon mesh in this example.

There does not appear to be a way to do this through the editor as you can only attach to a socket there. This has to be done via code.