[Client] Only play sounds from active cells when receiving ObjectSound

pull/593/head
David Cernat 3 years ago
parent 48de84ec32
commit dbae0bddc2

@ -21,7 +21,13 @@ namespace mwmp
if (!ptrCellStore) return;
objectList.playObjectSounds(ptrCellStore);
MWBase::World* world = MWBase::Environment::get().getWorld();
// Only play sounds in active cells
if (world->isCellActive(*ptrCellStore->getCell()))
{
objectList.playObjectSounds(ptrCellStore);
}
}
};

Loading…
Cancel
Save