mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-03-14 01:19:59 +00:00
Head tracking fix
This commit is contained in:
parent
31d28e727f
commit
c2771bc8ab
@ -626,10 +626,7 @@ Ogre::Vector3 NpcAnimation::runAnimation(float timepassed)
|
||||
|
||||
Ogre::Node* node = baseinst->getBone("Bip01 Head");
|
||||
if (node)
|
||||
{
|
||||
node->rotate(Ogre::Vector3::UNIT_Z, mHeadYaw, Ogre::Node::TS_WORLD);
|
||||
node->rotate(Ogre::Vector3::UNIT_X, mHeadPitch, Ogre::Node::TS_WORLD);
|
||||
}
|
||||
node->rotate(Ogre::Quaternion(mHeadYaw, Ogre::Vector3::UNIT_Z) * Ogre::Quaternion(mHeadPitch, Ogre::Vector3::UNIT_X), Ogre::Node::TS_WORLD);
|
||||
}
|
||||
mFirstPersonOffset = 0.f; // reset the X, Y, Z offset for the next frame.
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user