1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-02-06 04:15:33 +00:00

Fix unsafe use of BaseNode

This commit is contained in:
scrawl 2014-12-27 15:02:05 +01:00
parent 50e31877ab
commit a62fe38a1b

View file

@ -1214,7 +1214,7 @@ namespace MWMechanics
bool MechanicsManager::awarenessCheck(const MWWorld::Ptr &ptr, const MWWorld::Ptr &observer)
{
if (observer.getClass().getCreatureStats(observer).isDead())
if (observer.getClass().getCreatureStats(observer).isDead() || !observer.getRefData().isEnabled())
return false;
const MWWorld::Store<ESM::GameSetting>& store = MWBase::Environment::get().getWorld()->getStore().get<ESM::GameSetting>();