mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-03 11:45:34 +00:00
Unconditionally call actor->resetPosition in adjustPosition.
Revert broken change that would force adjust all actors in cell upon loading. That break floating corpses (and probably others things).
This commit is contained in:
parent
daf6c9f88f
commit
a314f196eb
2 changed files with 3 additions and 7 deletions
|
@ -253,7 +253,7 @@ namespace
|
|||
bool operator() (const MWWorld::Ptr& ptr)
|
||||
{
|
||||
if (!ptr.getRefData().isDeleted() && ptr.getRefData().isEnabled())
|
||||
ptr.getClass().adjustPosition (ptr, true);
|
||||
ptr.getClass().adjustPosition (ptr, false);
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
|
|
@ -1344,12 +1344,8 @@ namespace MWWorld
|
|||
}
|
||||
|
||||
moveObject(ptr, ptr.getCell(), pos.x(), pos.y(), pos.z());
|
||||
if (force) // force physics to use the new position
|
||||
{
|
||||
auto actor = mPhysics->getActor(ptr);
|
||||
if(actor)
|
||||
actor->resetPosition();
|
||||
}
|
||||
if (ptr.getClass().isActor())
|
||||
mPhysics->getActor(ptr)->resetPosition();
|
||||
}
|
||||
|
||||
void World::fixPosition()
|
||||
|
|
Loading…
Reference in a new issue