www.jpct.net
jPCT - a 3d engine for Java => Support => Topic started by: fireside on October 14, 2010, 05:05:14 am
-
I've forgotten how to do an absolute translation. It's basically a relative motion, so how do I do that when the object is not at the point of origin? Rotation doesn't matter in this case. I just need to either get it back to the origin or compensate somehow.
-
obj.clearTranslation();
obj.translate(...);
-
Thanks.
-
And with rotation?
I need the position and rotation for network play.
I try object.getTranslationMatrix() -> network -> object.setTranslationMatrix() but this not work.
I think object.getTranslation() -> network -> object.clearTranslation() -> object.translate() work (not tested) but how send the rotation?
-
As a matrix. You can get and set the rotation matrix.