I then exported the model as Ogre 3D(.scene and .mesh)
I then import the Ogre model in jmonkeyengine
The problems i am having:
Only the .mesh and .skeleton files are created but no material files
So in jmonkeyengine my character is just a red coloured image
Regarding animation:
I make 2 animations in blender “head movement” and “walk”,
-The red coloured girl image in jmonkey plays only the last animation that i have played in blender (if the last animation that i played in blender was head movemenet, in jmonkeyengine it only plays headmovement even if i call it for a walk).
If i import the blender model inside jmonkeyengine instead of the Ogre mesh, and use the .j3o file, it gives me null pointer exception at “control.addListener(this)”
Anyone can help me please to get out of these problems i amstruggling from 2 days,
@ayesha-kashif said:
- If i import the blender model inside jmonkeyengine instead of the Ogre mesh, and use the .j3o file, it gives me null pointer exception at "control.addListener(this)"
Most likely you are retrieving the control incorrectly. When reading a model from .blend, chances are it’s a Node with many children… one of those children will have the control. You can see this easily in the scene explorer.
@pspeed said:
Most likely you are retrieving the control incorrectly. When reading a model from .blend, chances are it's a Node with many children... one of those children will have the control. You can see this easily in the scene explorer.
Yes i have seen in the scene explorer and uploaded an image above as well. My animations are inside:
girl –> girlBody –> AnimControl
Although there is
girl –> AnimControl
but there is no animation
In my code i use :
control = player.getControl(AnimControl.class);
control.addListener(this);
channel = control.createChannel();
Can you please tell me how i can correctly retrive the control?
@ayesha-kashif said:
Thanks pspeed, now everything is fine ..... except the clothes, shoes etc which are some transparent things rather then the real clothes or shoes etc.
New proverb from 2014 : “A picture on imgur is worth a thousand pictures on dropbox”
I like the transparent clothes…and just out of curiosity… what are the animations on the girl_tongue01 Node?
First check the material, does it uses material colors (“useMaterialColors” checked). Is the diffuse color alpha something different than 1? if so set it to 1.
Else check the textures, maybe they have a non 1 alpha channel.
Then, check for each geometries that they are in the opaque bucket.
On a side note, this model is really not optimised for a game engine. The fact that you have fully modeled toes hidden by shoes it a huge waste of resource. Same for the legs and so on. Idk if makehuman has an option for that, but if it doesn’t IMO that would make it a no go for me.
I guess it’s ok if you have only this model…but still you should look into it.
@nehon said:
New proverb from 2014 : "A picture on imgur is worth a thousand pictures on dropbox"
Well, thanks for your reply and advices, one of them really worked… as shown in the image. I unchecked the alpha option and finally clothes are no more transparent.
On a side note, this model is really not optimised for a game engine. The fact that you have fully modeled toes hidden by shoes it a huge waste of resource. Same for the legs and so on. Idk if makehuman has an option for that, but if it doesn’t IMO that would make it a no go for me.
I guess it’s ok if you have only this model…but still you should look into it.
Yes, i will check for it… Also i have entered this gaming world a month and a half before…so not an expert but will try to optimize the stuff…