diff options
author | uruk | 2014-06-23 13:11:54 +0200 |
---|---|---|
committer | uruk | 2014-06-23 13:11:54 +0200 |
commit | 0eece817ebb5f6463467294f274da1dfb0b3164c (patch) | |
tree | 807978bc14de540c4f0f0e2baebb52858a9d63e9 /engines | |
parent | 23adc159ef4dff0a7d08ba2b11d9847805e5dea8 (diff) | |
download | scummvm-rg350-0eece817ebb5f6463467294f274da1dfb0b3164c.tar.gz scummvm-rg350-0eece817ebb5f6463467294f274da1dfb0b3164c.tar.bz2 scummvm-rg350-0eece817ebb5f6463467294f274da1dfb0b3164c.zip |
CGE2: Fix releasePocket().
Now the inventory system is working as intended.
Diffstat (limited to 'engines')
-rw-r--r-- | engines/cge2/cge2_main.cpp | 2 | ||||
-rw-r--r-- | engines/cge2/vga13h.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/engines/cge2/cge2_main.cpp b/engines/cge2/cge2_main.cpp index 797dbe22d1..6c572d0b46 100644 --- a/engines/cge2/cge2_main.cpp +++ b/engines/cge2/cge2_main.cpp @@ -796,7 +796,7 @@ void CGE2Engine::loadPos() { void CGE2Engine::releasePocket(Sprite *spr) { for (int i = 0; i < 2; i++) { for (int j = 0; j < kPocketMax; j++) { - Sprite *poc = _heroTab[i]->_pocket[j]; + Sprite *&poc = _heroTab[i]->_pocket[j]; if (poc == spr) { spr->_flags._kept = false; poc = nullptr; diff --git a/engines/cge2/vga13h.cpp b/engines/cge2/vga13h.cpp index 1c48a96210..2c8a3a6801 100644 --- a/engines/cge2/vga13h.cpp +++ b/engines/cge2/vga13h.cpp @@ -104,7 +104,7 @@ Sprite::Sprite(CGE2Engine *vm, BitmapPtr shpP, int cnt) Sprite::~Sprite() { if (_vm->_sprite == this) - _vm->_sprite = NULL; + _vm->_sprite = nullptr; contract(); } |