I try to create a game which consist of a lot of hexagons. My Problem is, that each side of each hexagon can have a different color. My first approach was to use a blender model where each side gets its own spatial where a material can be assigned. My model looks like this:
The Problem with that is, it cost a lot of performance. My framerate is dropping from about 2k fps (just the hexagon without the sides) to 400 fps. For my test case thats fine, but it will not work with android.
I thought a texture could solve the problem. But how can I assign it dynamic, so that each side could have a different color (depending on the game state).
-> Use a texture atlas, as then each can use the same material. There is an atlasTexture tool somwhere in jme’s source
-> Batch the resulting hexagons together.