MCPcopy Create free account
hub / github.com/OpenDungeons/OpenDungeons / restoreEntityState

Method restoreEntityState

source/entities/MovableGameEntity.cpp:378–392  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

376}
377
378void MovableGameEntity::restoreEntityState()
379{
380 GameEntity::restoreEntityState();
381 if(!mPrevAnimationState.empty())
382 {
383 RenderManager::getSingleton().rrSetObjectAnimationState(this, mPrevAnimationState, mPrevAnimationStateLoop);
384
385 if(mWalkDirection != Ogre::Vector3::ZERO)
386 RenderManager::getSingleton().rrOrientEntityToward(this, mWalkDirection);
387
388 // If the mesh has no skeleton, getAnimationState() could return null
389 if(getAnimationState() != nullptr)
390 getAnimationState()->addTime(mAnimationTime);
391 }
392}
393
394void MovableGameEntity::correctDropPosition(Ogre::Vector3& position)
395{

Callers

nothing calls this directly

Calls 2

rrOrientEntityTowardMethod · 0.80

Tested by

no test coverage detected