1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-30 09:45:36 +00:00

Don't unlock unlocked objects now that unlock is no longer idempotent

This commit is contained in:
Evil Eye 2023-06-11 09:43:42 +02:00
parent b62b5f363e
commit 24c1909d52
2 changed files with 3 additions and 3 deletions

View file

@ -954,8 +954,8 @@ namespace MWMechanics
if (caster == getPlayer())
MWBase::Environment::get().getWindowManager()->messageBox("#{sMagicOpenSuccess}");
target.getCellRef().unlock();
}
target.getCellRef().unlock();
}
else
{

View file

@ -366,8 +366,8 @@ namespace MWScript
void execute(Interpreter::Runtime& runtime) override
{
MWWorld::Ptr ptr = R()(runtime);
ptr.getCellRef().unlock();
if (ptr.getCellRef().isLocked())
ptr.getCellRef().unlock();
}
};