mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-22 07:53:52 +00:00
Scale the accumulation root translation
This commit is contained in:
parent
600fe06f00
commit
16933e3926
1 changed files with 2 additions and 2 deletions
|
@ -196,7 +196,7 @@ Ogre::Vector3 Animation::updatePosition(float time)
|
|||
posdiff = (mNonAccumRoot->getPosition() - mLastPosition) * mAccumulate;
|
||||
|
||||
/* Translate the accumulation root back to compensate for the move. */
|
||||
mAccumRoot->translate(-posdiff);
|
||||
mAccumRoot->translate(-posdiff * mAccumRoot->_getDerivedScale());
|
||||
mLastPosition += posdiff;
|
||||
}
|
||||
return posdiff;
|
||||
|
@ -220,7 +220,7 @@ void Animation::reset(const std::string &marker)
|
|||
if(mNonAccumRoot)
|
||||
{
|
||||
mLastPosition = mNonAccumRoot->getPosition();
|
||||
mAccumRoot->setPosition(mStartPosition - mLastPosition);
|
||||
mAccumRoot->setPosition((mStartPosition - mLastPosition) * mAccumRoot->_getDerivedScale());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue