mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-18 15:48:48 +00:00
HOPKINS: Fix bug #6456 - RTL not working.
This commit is contained in:
parent
6957c5bce0
commit
28955963d4
@ -1781,7 +1781,7 @@ void GraphicsManager::initScreen(const Common::String &file, int mode, bool init
|
||||
|
||||
do {
|
||||
int dataVal1 = _vm->_script->handleOpcode(ptr + 20 * dataOffset);
|
||||
if (_vm->shouldQuit())
|
||||
if (dataVal1 == -1 || _vm->shouldQuit())
|
||||
return;
|
||||
|
||||
if (dataVal1 == 2)
|
||||
|
@ -1923,7 +1923,6 @@ void HopkinsEngine::bombExplosion() {
|
||||
}
|
||||
|
||||
void HopkinsEngine::restoreSystem() {
|
||||
quitGame();
|
||||
_events->refreshEvents();
|
||||
}
|
||||
|
||||
@ -2913,4 +2912,7 @@ bool HopkinsEngine::isUnderwaterSubScene() {
|
||||
return (_globals->_curRoomNum >= 77) && (_globals->_curRoomNum <= 89);
|
||||
}
|
||||
|
||||
bool HopkinsEngine::shouldQuit() {
|
||||
return getEventManager()->shouldQuit() || getEventManager()->shouldRTL();
|
||||
}
|
||||
} // End of namespace Hopkins
|
||||
|
@ -168,6 +168,7 @@ public:
|
||||
uint16 getVersion() const;
|
||||
bool getIsDemo() const;
|
||||
const Common::String &getTargetName() const;
|
||||
bool shouldQuit();
|
||||
|
||||
int getRandomNumber(int maxNumber);
|
||||
Common::String generateSaveName(int slotNumber);
|
||||
|
@ -2629,7 +2629,7 @@ void ObjectsManager::loadObjectIniFile() {
|
||||
|
||||
for (;;) {
|
||||
int opcodeType = _vm->_script->handleOpcode(data + 20 * lastOpcodeResult);
|
||||
if (_vm->shouldQuit())
|
||||
if (opcodeType == -1 || _vm->shouldQuit())
|
||||
return;
|
||||
|
||||
if (opcodeType == 2)
|
||||
|
@ -825,7 +825,7 @@ void TalkManager::handleAnswer(int zone, int verb) {
|
||||
int lastOpcodeResult = 1;
|
||||
do {
|
||||
int opcodeType = _vm->_script->handleOpcode(ptr + 20 * lastOpcodeResult);
|
||||
if (_vm->shouldQuit())
|
||||
if (opcodeType == -1 || _vm->shouldQuit())
|
||||
return;
|
||||
|
||||
if (opcodeType == 2)
|
||||
|
Loading…
Reference in New Issue
Block a user