object rotation help

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
phillip
Posts: 14
Joined: Thu Nov 05, 2009 9:04 pm

object rotation help

Post by phillip »

Hello all. Could some one point me in the right direction. Here is what i want to achieve. I have 3 cube objects loaded in my scene. The middle is my first cube node which is the parent the other 2 cube nodes is positioned 1 on the left and the other on the right side of the parent. When i rotate or move the parent node I would like the other 2 nodes to follow the parent node's angle and position but keep it position along side the parent. Something like a turret. Is there a tech term for this. I tried the forum but I don't know what to search for. Thank you in advance
kazymjir
Posts: 727
Joined: Sat Feb 20, 2010 4:05 pm
Location: Munich, Bayern

Post by kazymjir »

Those two cubes have to be child of your cube in the middle - the parent.
Use addChild(ISceneNode* child) from ISceneNode to attach those two child cubes to the parent cube.
http://irrlicht.sourceforge.net/docu/cl ... 5225350970
Post Reply