I’m thinking of putting a game together and one thing I would like to be able to do is have characters with interchangeable equipment, partly so that the player’s character can have different outfits and partly so I can do the old trick of using the same model with different textures for a bunch of different NPCs.
The problem I’m running into is how to make them so that they are easy to change and I was wondering whether anyone else here has done this?
One way that I’ve seen suggested is to have a second mesh surrounding your regular character mesh to represent their clothes and using alpha-blended textures so that you can apply different shirt textures or whatever to the outside mesh and they match the animation of the model. I think this is what WoW does. It Doesn’t allow for a lot of variety in shape of outfit but probably enough for my purposes.
As far as I can tell the main alternative is to create separate equipment models, which I think may work out too hard given that in order to have some chance of getting the project finished I plan to use keyframed animations rather than skin and bones and making the models match up could end up being a lot of very hard work.
Any other methods people could use or have used successfully? Other thoughts on ways I could be doing this?
You take a model’s already animated/rigged clothing/body or whatever and then you duplicate it and give it another name such as armor.00 or whatever and then you UV map it and slightly modify it. Next you simply make a whole lot of copies of your character featuring every possible combinition of armor their might be. ANd then, you tell the computer to call up that object when they are wearing the appropriate equipment.
Now for small accessories like rings or whatever, a little scripting and contraint usage could sufface.
I had thought of doing it that way, but it seems to me it would exponentially increase the number of models required and ignoring the unsightly DRY violation that might upset my finer programming instincts my concern would be that I would end up with a huge file size, which given that any money I make from it will be on downloads is likely to put of potential users.
Also if one animation wasn’t working properly in the original model i could have a hell of a time fixing it across every variant and testing them all independantly.
It is an easy solution, however which may make it useful from that point of view. Another option to consider, certainly.