I need some help (again
I already tried to move the center (that point in the center of the model) to the feet, but it didn't work, and if I use the ninja model provided with Irrlicht (and the same code), it works fine.



yeah mine works too. strange.CuteAlien wrote:Well, at least it worked that way for me so far...
Code: Select all
void moveTo(IAnimatedMeshSceneNode* node, vector3df finalPosition)
{
vector3df actualPosition;
actualPosition = node->getPosition();
posDiff = finalPosition - actualPosition;
posDiff.normalize();
degree = atan2(posDiff.X,posDiff.Z) * core::RADTODEG;
node->setRotation(vector3df(0,degree,0));
node->setPosition(finalPosition);
}