diff options
author | Filippos Karapetis | 2011-12-06 03:34:36 +0200 |
---|---|---|
committer | Filippos Karapetis | 2011-12-06 03:34:36 +0200 |
commit | bdfd481a68f6a4830f1b18adcf8fe2fa171498b5 (patch) | |
tree | 2fbf78e524dc3bcf3ba3a9ad0c6caf2043d1d102 /engines/dreamweb/stubs.cpp | |
parent | e1a53cc455c79ce72415581d01aeacc86ee9a2eb (diff) | |
download | scummvm-rg350-bdfd481a68f6a4830f1b18adcf8fe2fa171498b5.tar.gz scummvm-rg350-bdfd481a68f6a4830f1b18adcf8fe2fa171498b5.tar.bz2 scummvm-rg350-bdfd481a68f6a4830f1b18adcf8fe2fa171498b5.zip |
DREAMWEB: 'settopleft', 'settopright', 'setbotleft', 'setbotright' ported to C++
Diffstat (limited to 'engines/dreamweb/stubs.cpp')
-rw-r--r-- | engines/dreamweb/stubs.cpp | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp index 5fb861c360..ca1f3c1d38 100644 --- a/engines/dreamweb/stubs.cpp +++ b/engines/dreamweb/stubs.cpp @@ -3384,5 +3384,65 @@ void DreamGenContext::intro() { data.byte(kLasthardkey) = 0; } +void DreamGenContext::setTopLeft() { + if (data.byte(kSymboltopdir) != 0) { + blank(); + return; + } + + if (data.byte(kCommandtype) != 210) { + data.byte(kCommandtype) = 210; + commandOnly(19); + } + + if (data.word(kMousebutton) != 0); + data.byte(kSymboltopdir) = 0xFF; +} + +void DreamGenContext::setTopRight() { + if (data.byte(kSymboltopdir) != 0) { + blank(); + return; + } + + if (data.byte(kCommandtype) != 211) { + data.byte(kCommandtype) = 211; + commandOnly(20); + } + + if (data.word(kMousebutton) != 0); + data.byte(kSymboltopdir) = 1; +} + +void DreamGenContext::setBotLeft() { + if (data.byte(kSymbolbotdir) != 0) { + blank(); + return; + } + + if (data.byte(kCommandtype) != 212) { + data.byte(kCommandtype) = 212; + commandOnly(21); + } + + if (data.word(kMousebutton) != 0); + data.byte(kSymbolbotdir) = 0xFF; +} + +void DreamGenContext::setBotRight() { + if (data.byte(kSymbolbotdir) != 0) { + blank(); + return; + } + + if (data.byte(kCommandtype) != 213) { + data.byte(kCommandtype) = 213; + commandOnly(22); + } + + if (data.word(kMousebutton) != 0); + data.byte(kSymbolbotdir) = 1; +} + } /*namespace dreamgen */ |