Help to rotation

Any documentations about rotating in specific the JMonkey engine? I really haven't got a clue what the different things means, and my game is going very slow in development just because of this subject

If no documentation about it, anyone would mind use like a half hour and create one. And make my BIG troubles almost disappear.





Thank you in advance!



Regards

hiya,

there is a lot of information in the jme wiki. -> rotation



There are also Tutorials and a lot more Code Snippets about specific subjects.

Tthis should get you started.

I already read that, but aren't helping me much.

I need more documentation on how quaternion and the render do stuff



example:


public void update(float time) {
   c.update(time);
   node.getLocalRotation().fromAngleNormalAxis(0.5f, tmp.addLocal(0, 0, 0.01f));      
   node.updateGeometricState(0, true);      
}


Why do that make the node disappear when it reach around 900 degrees?

or


Quaternion q = new Quaternion().fromAngleAxis((float)Math.PI / 180, tmp);
@Override
public void update(float time) {
   c.update(time);
   
   node.getLocalRotation().addLocal(q);
   
   node.updateGeometricState(0, true);      
}


why do that make the node disappear at the start.


Thanks

hmm, what did you set 'tmp' to?

I found out how to it, I just



getLocalRotation().fromAngleNormalAxis(angle, new Vector3f(0,0,0));

And the way I wants to change it is 1 instead of 0 in the Vector3f, didn't knew it was so simple.



Thanks core-dump for get me to read the wiki another time.



Take care.

glad i could help :slight_smile: