mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-03-26 20:37:25 +00:00
Do not respawn container if player did not touch it
This commit is contained in:
parent
c01153569d
commit
29cfd2c583
@ -89,6 +89,10 @@ namespace MWClass
|
||||
ptr.get<ESM::Container>();
|
||||
if (ref->mBase->mFlags & ESM::Container::Respawn)
|
||||
{
|
||||
// Container was not touched, there is no need to modify its content.
|
||||
if (ptr.getRefData().getCustomData() == nullptr)
|
||||
return;
|
||||
|
||||
MWBase::Environment::get().getWorld()->removeContainerScripts(ptr);
|
||||
ptr.getRefData().setCustomData(nullptr);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user