🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Customizable character equipment - How to?

Started by
0 comments, last by -Tau- 4 years, 3 months ago

So I was wondering, how do you make armor and clothes for RPG characters?

When you have a character and you want him/her to be able to wear different clothes, how do you go about it? Especially if you want to be able to customize your characters for example height, race, etc...

How do game developers usually do this in a way that’s not only easy to code but also doesn’t require too much work on the part of the graphics team?

Right now in my game I have a character that can equip different weapons, but this is easy. There’s a “holding bone” in the model and when the character is holding an item, the model of that item simply uses this bone as world matrix. I assume something like this could be used for helmets too, however, if want to be able to customize characters, this bone would also need to change.

For example a dwarf and an orc being able to equip the same helm, the model of that helm would have to change to fit on the head of both.

First solution to this might be that the “wear on head bone” would be different for different races and would also slightly change after character customization.

Second solution that I can think of might be to tell to graphics design team to make separate helmets for different races. However, here I think would be the problems that first, we would need a lot more models of the same thing and second, that the “wear on head bone” still has to be adjusted after character customization.

Then there’s the issue with chest piece and legs. These models would have to be animated or at least rigged, so that they move together with character.

The only idea that I have on hove to do this would be to first have model of clothes or armor, let’s say legs, and add hip, left upper leg, left lower leg, right upper leg, right lower leg bones to it. No animation, just rigging.

Then add “clothes bone” to each bone of the character, load clothes model into character model and adjust characters “clothes bone” so that the clothes model fits. This could work for different races as it would require only one clothes model and also for character customization, because if you would for example change the height of character, make the legs longer, the clothes bones would also stretch, therefore the model would stretch too. Then in the code simple update clothes bones based on character clothes bones and that’s it.

However, here I see a problem that this would work only for one clothes model. The moment we add a new clothes model, we would have to make sure that this new model fits all races, so I’m not sure how to go about this.

How is something like this usually dealt with in games?

This topic is closed to new replies.

Advertisement