CustomSceneNode Turning to center
hi
I am a student who is studying irrlicht.
It is question about turning of position that I want.
See image.
stop image
1.http://pds4.egloos.com/pds/200701/25/56 ... 010974.jpg
node->setRotation(45); 1 -> 2
2.http://pds5.egloos.com/pds/200701/25/56 ... 012916.jpg
Position that I want to rotate! 1 -> 3
3.http://pds5.egloos.com/pds/200701/25/56 ... 014957.jpg
Want to rotate to center that is marked in 3 times image.
Want to rotate to indication position .
Thank you for reading writing .
CustomSceneNode Turning to center
the easyest way is to make center of your four rectangles node to be its origin. This can be done in diferent ways depending howe you made your node.
If it is for some reason unpossible than you gona have some hard time making some calculations involving vectors and trigonometry. If you are skiled in mathematics than you may want to use matrices as well. Look at vector2d and matrix4 classes since they have some useful functions you may use.
If it is for some reason unpossible than you gona have some hard time making some calculations involving vectors and trigonometry. If you are skiled in mathematics than you may want to use matrices as well. Look at vector2d and matrix4 classes since they have some useful functions you may use.