diff options
author | Thanasis Antoniou | 2019-11-08 16:27:25 +0200 |
---|---|---|
committer | Thanasis Antoniou | 2019-11-08 16:28:18 +0200 |
commit | 4af463476b1ded9dd94ee53d19dc071a2c4a4753 (patch) | |
tree | 57285bcd0b77fd3ded8fab59bdf8c3f46c417994 /engines/bladerunner | |
parent | f74f8e3c531c9020e6646c0aa4fabf76e69070f5 (diff) | |
download | scummvm-rg350-4af463476b1ded9dd94ee53d19dc071a2c4a4753.tar.gz scummvm-rg350-4af463476b1ded9dd94ee53d19dc071a2c4a4753.tar.bz2 scummvm-rg350-4af463476b1ded9dd94ee53d19dc071a2c4a4753.zip |
BLADERUNNER: Fix wrong order for GPS map selection
Diffstat (limited to 'engines/bladerunner')
-rw-r--r-- | engines/bladerunner/ui/spinner.cpp | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/engines/bladerunner/ui/spinner.cpp b/engines/bladerunner/ui/spinner.cpp index 4e7379d4d0..c6d42b0a52 100644 --- a/engines/bladerunner/ui/spinner.cpp +++ b/engines/bladerunner/ui/spinner.cpp @@ -105,15 +105,24 @@ int Spinner::chooseDestination(int loopId, bool immediately) { _destinations = nullptr; int spinnerLoopId = 4; - if (mapmask & 1) { - _destinations = getDestinationsNear(); - spinnerLoopId = 0; + // mapmask determines which map version will be displayed + // Depending on which destinations are available, mapmaks will have value: + // 1: For the near view (first chapter locations, and animoid row for some reason) + // 3: For medium view locations (includes the near view ones) + // 7: For far view locations (includes all the previous ones) + // This values are determined in mapmaskv table + // + // Since the checks below use bitwise AND, we need to check in order + // from the "far" version to the "near" version + if (mapmask & 4) { + _destinations = getDestinationsFar(); + spinnerLoopId = 4; } else if (mapmask & 2) { _destinations = getDestinationsMedium(); spinnerLoopId = 2; - } else if (mapmask & 4) { - _destinations = getDestinationsFar(); - spinnerLoopId = 4; + } else if (mapmask & 1) { + _destinations = getDestinationsNear(); + spinnerLoopId = 0; } else { return -1; } |