diff options
Diffstat (limited to 'engines/dreamweb')
-rw-r--r-- | engines/dreamweb/monitor.cpp | 12 | ||||
-rw-r--r-- | engines/dreamweb/stubs.h | 2 |
2 files changed, 6 insertions, 8 deletions
diff --git a/engines/dreamweb/monitor.cpp b/engines/dreamweb/monitor.cpp index 7e88838a7d..72cb4a3735 100644 --- a/engines/dreamweb/monitor.cpp +++ b/engines/dreamweb/monitor.cpp @@ -436,7 +436,7 @@ void DreamBase::showKeys() { scrollMonitor(); } -void DreamGenContext::getKeyAndLogo() { +bool DreamGenContext::getKeyAndLogo() { byte newLogo = es.byte(bx + 1) - 48; byte keyNum = es.byte(bx + 1 + 2) - 48; bx += 1 + 2 + 1; @@ -444,12 +444,12 @@ void DreamGenContext::getKeyAndLogo() { if (monitorKeyEntries[keyNum].keyAssigned == 1) { // Key OK data.byte(kLogonum) = newLogo; - al = 0; + return false; } else { monMessage(12); // "Access denied, key required -" monPrint(monitorKeyEntries[keyNum].username); scrollMonitor(); - al = 1; + return true; } } @@ -484,8 +484,7 @@ void DreamGenContext::dirFile() { } // "foundfile" - getKeyAndLogo(); - if (al != 0) + if (getKeyAndLogo()) return; // "keyok2" @@ -572,8 +571,7 @@ void DreamGenContext::read() { } // "foundfile2" - getKeyAndLogo(); - if (al != 0) + if (getKeyAndLogo()) return; // "keyok1" diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h index 9cbb286022..ce2fefb615 100644 --- a/engines/dreamweb/stubs.h +++ b/engines/dreamweb/stubs.h @@ -90,7 +90,7 @@ bool execCommand(); void identifyOb(); void selectOb(); - void getKeyAndLogo(); + bool getKeyAndLogo(); void read(); void dirCom(); void searchForString(); |