diff options
author | Bastien Bouclet | 2017-08-27 15:55:11 +0200 |
---|---|---|
committer | Bastien Bouclet | 2017-09-12 20:25:24 +0200 |
commit | 64967c6222dd4a3eb0589ba970ff27c57f3461bb (patch) | |
tree | 0ea3d0b81f2dde0f8ac7a8adca7e9bcce420de96 /engines/pegasus | |
parent | 6506b95fceb603c79bdd67a30bf82739bd7e463e (diff) | |
download | scummvm-rg350-64967c6222dd4a3eb0589ba970ff27c57f3461bb.tar.gz scummvm-rg350-64967c6222dd4a3eb0589ba970ff27c57f3461bb.tar.bz2 scummvm-rg350-64967c6222dd4a3eb0589ba970ff27c57f3461bb.zip |
PEGASUS: Reset the Pegasus biochip when toggling the shared screen space
Fixes a crash to debugger in the following case:
- TSA: Select he Pegasus biochip. The recall button is disabled.
- Select the gas canister in the inventory
- Jump to Norad VI
- Press T to show the Pegasus biochip. The recall button is still
incorrectly disabled. Clicking on it triggers an error.
Diffstat (limited to 'engines/pegasus')
-rw-r--r-- | engines/pegasus/items/biochips/pegasuschip.cpp | 5 | ||||
-rw-r--r-- | engines/pegasus/items/biochips/pegasuschip.h | 2 |
2 files changed, 7 insertions, 0 deletions
diff --git a/engines/pegasus/items/biochips/pegasuschip.cpp b/engines/pegasus/items/biochips/pegasuschip.cpp index c74cc346ca..574316b5ca 100644 --- a/engines/pegasus/items/biochips/pegasuschip.cpp +++ b/engines/pegasus/items/biochips/pegasuschip.cpp @@ -49,6 +49,11 @@ void PegasusChip::select() { setUpPegasusChip(); } +void PegasusChip::takeSharedArea() { + BiochipItem::takeSharedArea(); + setUpPegasusChip(); +} + void PegasusChip::setUpPegasusChip() { switch (GameState.getCurrentNeighborhood()) { case kCaldoriaID: diff --git a/engines/pegasus/items/biochips/pegasuschip.h b/engines/pegasus/items/biochips/pegasuschip.h index c4f1e6cd84..b81df94b39 100644 --- a/engines/pegasus/items/biochips/pegasuschip.h +++ b/engines/pegasus/items/biochips/pegasuschip.h @@ -38,6 +38,8 @@ public: void select(); + void takeSharedArea() override; + void setUpPegasusChip(); // Called to set up the Pegasus chip when the Pegasus chip is the current chip but does not |