diff options
author | Paul Gilbert | 2017-02-18 17:06:30 -0500 |
---|---|---|
committer | Paul Gilbert | 2017-02-18 17:06:30 -0500 |
commit | 0343c0d3378fac49af4e0e0c8c82d4bf3c6404b6 (patch) | |
tree | e71c2acdf2bad9e84ae2b24d9ebae36ccf1137d7 /engines | |
parent | d65c717a448d9afe9dc820756fa16e835d31176e (diff) | |
download | scummvm-rg350-0343c0d3378fac49af4e0e0c8c82d4bf3c6404b6.tar.gz scummvm-rg350-0343c0d3378fac49af4e0e0c8c82d4bf3c6404b6.tar.bz2 scummvm-rg350-0343c0d3378fac49af4e0e0c8c82d4bf3c6404b6.zip |
TITANIC: Fix adding held items to inventory after unlocking arms
Diffstat (limited to 'engines')
-rw-r--r-- | engines/titanic/carry/arm.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/engines/titanic/carry/arm.cpp b/engines/titanic/carry/arm.cpp index a843b5bb33..e7d340d6cb 100644 --- a/engines/titanic/carry/arm.cpp +++ b/engines/titanic/carry/arm.cpp @@ -164,10 +164,10 @@ bool CArm::MaitreDHappyMsg(CMaitreDHappyMsg *msg) { if (!_armUnlocked) playSound("z#47.wav"); if (_heldItemName == "Key" || _heldItemName == "AuditoryCentre") { - CGameObject *child = dynamic_cast<CGameObject *>(getFirstChild()); - if (child) { - child->setVisible(true); - petAddToInventory(); + CGameObject *heldItem = dynamic_cast<CGameObject *>(getFirstChild()); + if (heldItem) { + heldItem->setVisible(true); + heldItem->petAddToInventory(); } _visibleFrame = _unlockedFrame; |