aboutsummaryrefslogtreecommitdiff
path: root/engines/adl/hires1.cpp
diff options
context:
space:
mode:
authorWalter van Niftrik2016-03-06 13:36:35 +0100
committerWalter van Niftrik2016-03-09 10:03:13 +0100
commita73dcdf224ae88c7bcf73d754781052835af4cd0 (patch)
tree32cbc11bc95fb795c6df90eca3183cf0f464a281 /engines/adl/hires1.cpp
parentaf42795ffa9331a16c1c6fa819f5c3960fd3cfe1 (diff)
downloadscummvm-rg350-a73dcdf224ae88c7bcf73d754781052835af4cd0.tar.gz
scummvm-rg350-a73dcdf224ae88c7bcf73d754781052835af4cd0.tar.bz2
scummvm-rg350-a73dcdf224ae88c7bcf73d754781052835af4cd0.zip
ADL: Move functionality into base class
Diffstat (limited to 'engines/adl/hires1.cpp')
-rw-r--r--engines/adl/hires1.cpp52
1 files changed, 1 insertions, 51 deletions
diff --git a/engines/adl/hires1.cpp b/engines/adl/hires1.cpp
index 91407808eb..11d576b217 100644
--- a/engines/adl/hires1.cpp
+++ b/engines/adl/hires1.cpp
@@ -312,9 +312,7 @@ void HiRes1Engine::restartGame() {
printASCIIString("\r\r\r\r\r");
}
-void HiRes1Engine::runGame() {
- _display->setMode(DISPLAY_MODE_MIXED);
-
+void HiRes1Engine::loadData() {
Common::File f;
if (!f.open(IDS_HR1_MESSAGES))
@@ -385,54 +383,6 @@ void HiRes1Engine::runGame() {
f.seek(IDI_HR1_OFS_NOUNS);
loadNouns(f);
-
- printASCIIString("\r\r\r\r\r");
-
- while (1) {
- uint verb = 0, noun = 0;
-
- // When restoring from the launcher, we don't read
- // input on the first iteration. This is needed to
- // ensure that restoring from the launcher and
- // restoring in-game brings us to the same game state.
- // (Also see comment below.)
- if (!_isRestoring) {
- clearScreen();
- showRoom();
-
- _canSaveNow = _canRestoreNow = true;
- getInput(verb, noun);
- _canSaveNow = _canRestoreNow = false;
-
- if (shouldQuit())
- return;
-
- if (!doOneCommand(_roomCommands, verb, noun))
- printMessage(IDI_HR1_MSG_DONT_UNDERSTAND);
- }
-
- if (_isRestoring) {
- // We restored from the GMM or launcher. As restoring
- // with "RESTORE GAME" does not end command processing,
- // we don't break it off here either. This essentially
- // means that restoring a game will always run through
- // the global commands and increase the move counter
- // before the first user input.
- printASCIIString("\r");
- _isRestoring = false;
- verb = _restoreVerb;
- noun = _restoreNoun;
- }
-
- // Restarting does end command processing
- if (_isRestarting) {
- _isRestarting = false;
- continue;
- }
-
- doAllCommands(_globalCommands, verb, noun);
- _state.moves++;
- }
}
void HiRes1Engine::printMessage(uint idx, bool wait) {