mirror of
https://github.com/TES3MP/TES3MP.git
synced 2025-09-29 08:00:56 -04:00
Don't update the character controller while paused
This commit is contained in:
parent
d2f5a886c7
commit
daad8d9859
@ -260,16 +260,18 @@ namespace MWMechanics
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
std::vector<std::pair<std::string, Ogre::Vector3> > movement;
|
if(!paused)
|
||||||
for(PtrControllerMap::iterator iter(mActors.begin());iter != mActors.end();++iter)
|
|
||||||
{
|
{
|
||||||
iter->second.update(duration);
|
std::vector<std::pair<std::string, Ogre::Vector3> > movement;
|
||||||
Ogre::Vector3 vector = MWWorld::Class::get(iter->first).getMovementVector(iter->first);
|
for(PtrControllerMap::iterator iter(mActors.begin());iter != mActors.end();++iter)
|
||||||
if(vector!=Ogre::Vector3::ZERO)
|
{
|
||||||
movement.push_back(std::make_pair(iter->first.getRefData().getHandle(), vector));
|
iter->second.update(duration);
|
||||||
}
|
Ogre::Vector3 vector = MWWorld::Class::get(iter->first).getMovementVector(iter->first);
|
||||||
if (!paused)
|
if(vector!=Ogre::Vector3::ZERO)
|
||||||
|
movement.push_back(std::make_pair(iter->first.getRefData().getHandle(), vector));
|
||||||
|
}
|
||||||
MWBase::Environment::get().getWorld()->doPhysics (movement, duration);
|
MWBase::Environment::get().getWorld()->doPhysics (movement, duration);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Actors::restoreDynamicStats()
|
void Actors::restoreDynamicStats()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user