1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-16 16:10:58 +00:00

Merge pull request #1390 from akortunov/referencecheck

Do not make target reference unavailable on cell change
This commit is contained in:
scrawl 2017-08-12 18:48:52 +00:00 committed by GitHub
commit 1bdcecc32e

View File

@ -20,9 +20,8 @@ namespace MWGui
{
MWWorld::CellStore* playerCell = MWMechanics::getPlayer().getCell();
// check if player has changed cell, or count of the reference has become 0
if ((playerCell != mCurrentPlayerCell && mCurrentPlayerCell != NULL)
|| (!mPtr.isEmpty() && mPtr.getRefData().getCount() == 0))
// check if count of the reference has become 0
if (!mPtr.isEmpty() && mPtr.getRefData().getCount() == 0)
{
if (!mPtr.isEmpty())
{