diff options
author | Willem Jan Palenstijn | 2011-12-08 00:08:25 +0100 |
---|---|---|
committer | Willem Jan Palenstijn | 2011-12-08 00:08:25 +0100 |
commit | 5ab404f5bae87b6aac031232259ead2b3cf6386b (patch) | |
tree | ed5513c23a57cca600e01f6c06af989cf7ef7bb8 /engines/dreamweb | |
parent | b02a957f77373f78151707ec45fefe95e4555282 (diff) | |
download | scummvm-rg350-5ab404f5bae87b6aac031232259ead2b3cf6386b.tar.gz scummvm-rg350-5ab404f5bae87b6aac031232259ead2b3cf6386b.tar.bz2 scummvm-rg350-5ab404f5bae87b6aac031232259ead2b3cf6386b.zip |
DREAMWEB: Reduce code duplication
Diffstat (limited to 'engines/dreamweb')
-rw-r--r-- | engines/dreamweb/stubs.cpp | 36 |
1 files changed, 15 insertions, 21 deletions
diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp index 637df6019a..839665dd67 100644 --- a/engines/dreamweb/stubs.cpp +++ b/engines/dreamweb/stubs.cpp @@ -3245,20 +3245,14 @@ void DreamGenContext::runIntroSeq() { do { vSync(); - if (data.byte(kLasthardkey) == 1) { - getRidOfTempText(); - clearBeforeLoad(); - return; // "earlyendrun" - } + if (data.byte(kLasthardkey) == 1) + break; spriteUpdate(); vSync(); - if (data.byte(kLasthardkey) == 1) { - getRidOfTempText(); - clearBeforeLoad(); - return; // "earlyendrun" - } + if (data.byte(kLasthardkey) == 1) + break; delEverything(); printSprites(); @@ -3267,23 +3261,23 @@ void DreamGenContext::runIntroSeq() { useTimedText(); vSync(); - if (data.byte(kLasthardkey) == 1) { - getRidOfTempText(); - clearBeforeLoad(); - return; // "earlyendrun" - } + if (data.byte(kLasthardkey) == 1) + break; dumpMap(); dumpTimedText(); vSync(); - if (data.byte(kLasthardkey) == 1) { - getRidOfTempText(); - clearBeforeLoad(); - return; // "earlyendrun" - } + if (data.byte(kLasthardkey) == 1) + break; + + } while (data.byte(kGetback) != 1); - } while (data.byte(kGetback) != 1); + + if (data.byte(kLasthardkey) == 1) { + getRidOfTempText(); + clearBeforeLoad(); + } // These were not called in this program arc // in the original code.. Bug? |