Swapping Equipment - Big Newbie!

Hey guys,

I'm a really big newbie and I just started working with JME.

My friend and I are planning to create a game in which people are able to create characters with highly customized appearances - meaning, they can change clothes, equipment, etc.

How can we have characters change equipment? And is this functionality provided by coding or by the animation program?

Also, we're thinking there will be lots of combinations so we want to create a standard torso and legs and arms but just make many different faces.

We were wondering how can we do both of these things in JME?


David Pham

Hi David :slight_smile:

There was a post a little while ago about customisable faces, which might be helpful http://www.jmonkeyengine.com/jmeforum/index.php?topic=4312.0

For equipment, a common method is to have a placeholder or attachment point on the models, with a special name or some other way of finding it when the model is loaded. For example, planes in my game have gun0, gun1 etc. to show where to attach guns, and the same system is used for propellers, smoke effects, collision shapes etc.

I’m only familiar with doing this in blender, but basically you create a named “empty” object with no mesh data, and that will end up as a Node in the model. When you load the model you just search for the named child Nodes of the model, then attach stuff to them, like weapons etc. If the nodes are animated, they will move their child attachments around with them, so you can make them track with a hand for a weapon, etc.

You can also do a lot with textures, for different armour for example, although different meshes will look better.