• General Chat
  • Creating Characters with Interchangeable Clothing and Armor

Background: So I've been messing around with Godot's 3D engine for a couple weeks now. I've created some scenes, imported Meshes, used PBR textures, and even got my characters to animate, collide, and move around smoothly. I'm on to my next challenge: Clothing

Sometimes my characters will be wearing some type of chain mail, and other times plate, or just a tunic. Most RPGs have a way of rendering your character with a certain type of armor. I realize the brute force way is to render a version of all of my characters wearing their various armor types. Obviously, I don't want to do that - especially if I'm mixing and matching armor types(e.g. Plate Chest, mail arms, and leather gloves). So...

Question: What is the best approach for creating Interchangeable clothing and armor for 3D characters? Before I create my own system I want to know, First: Is there already a really easy way to do this in Godot that I'm unaware of(e.g. Unity's UMA system)? If not, what is the best approach? And what have other people done to solve this problem?

My Current Approach Right now, the approach I'm taking is using a 3D Model with multiple surface areas so that I can set different textures to imply clothing, mail, Gambeson, etc. If that's not good enough, (which I'm pretty sure it won't be) I think I'll create a 3D model where I can try to rip off areas like a hand and replace it with an entirely different mesh like a glove during runtime - and hope there's a way I can do it without ruining the rigging for my animations.

I would appreciate any insight the community can offer. Even cautionary tales of failed attempts would be appreciated. Thanks!

While I don't have this in my pipeline currently...I will soon. So I'm interested in this as well :)

-emo

@dustin Have you seen this? Not sure if it helps. Maybe in the right direction?

-emo

4 days later

@emo10001 thanks for responding.

That is a pretty good, concise demonstration of one approach for weapons. And not something I knew how to do, so thanks for posting.

But I don't think it's the ideal solution for armor. Armor, ideally, should replace the skin, not attach to it. Otherwise, the engine has to spend time rendering both, and then culling the skin. Or worse, it can run the risk of clothing and armor clipping each other.

I've since decided to take on a massive project to see if there's a way to solve this to give an easy option for everybody. Here's the link to my latest devlog if you're interested.

a month later

You might try hiding or deleting the vertices under the clothing item. The clothing item has it's own rigging and is animated at the same time as the human rig. With the vertices deleted at the clothing items location. If you can hide them that would be best.

4 years later

Hey i try to achieve something similar, do someone came up with a solution already ?
Im interested how to make specific bodyparts chooseable, like hovering over them and detect each one of them.

It is possible to seperate the 3D Model but then its getting hard to animate them.

    Genie like hovering over them and detect each one of them.

    I would expect that would usually be done by skeleton/bones since the model would have corresponding vertex groups/weights. You can then be clever about bone chains such as arms, since they would usually be named consistently such as Left_Arm_shoulder Left_Arm_Fore or such. But it also highlights the very nature of how this will need a custom solution since each production is different. In it's naming scheme as well as other specifics. Will there be some additional utility bones for say swords, shields guns bows or whatever else.

      Megalomaniak
      Is godot capable to detect the corresponding vertex groups/weights that are in the area of bones ?

      Genie Hey i try to achieve something similar, do someone came up with a solution already ?

      About the change of clothes — here. Hiding invisible body parts under clothes is a bit more complicated. In general, it was suggested to "slice" the body and hide the areas under a particular piece of clothing.

        Tomcat it was suggested to "slice" the body and hide the areas under a particular piece of clothing.

        Yes, and to add, slicing the mesh up like this by default causes visible seams in mesh shading because of vertex normals orientation changing. But most DCC applications should be able to create custom normal data so you can manually tweak the normals orientation per vertex to hide/fix the shading issues that stem from the default normals orientation.

        https://docs.blender.org/manual/en/2.79/modeling/meshes/editing/normals.html#custom-split-normals

          Megalomaniak Yes, and to add, slicing the mesh up like this by default causes visible seams in mesh shading because of vertex normals orientation changing.

          Yeah, that's one of the problems with this method 😃