diff options
| author | Willem Jan Palenstijn | 2011-11-14 18:51:15 +0100 |
|---|---|---|
| committer | Willem Jan Palenstijn | 2011-11-14 21:43:35 +0100 |
| commit | ceb36fe0d634f38200dad4e18b5c74464d3a0a13 (patch) | |
| tree | 5ef7cc72b0d52ff246f81c30d78f2d19d651137e /engines/dreamweb/object.cpp | |
| parent | 0ecdf85280bd60eae92bd7b08c0f9dd32c97fa05 (diff) | |
| download | scummvm-rg350-ceb36fe0d634f38200dad4e18b5c74464d3a0a13.tar.gz scummvm-rg350-ceb36fe0d634f38200dad4e18b5c74464d3a0a13.tar.bz2 scummvm-rg350-ceb36fe0d634f38200dad4e18b5c74464d3a0a13.zip | |
DREAMWEB: Move 'examineob' from dreamgen
Diffstat (limited to 'engines/dreamweb/object.cpp')
| -rw-r--r-- | engines/dreamweb/object.cpp | 76 |
1 files changed, 76 insertions, 0 deletions
diff --git a/engines/dreamweb/object.cpp b/engines/dreamweb/object.cpp index e2da902465..a1d6e1da7c 100644 --- a/engines/dreamweb/object.cpp +++ b/engines/dreamweb/object.cpp @@ -110,5 +110,81 @@ void DreamGenContext::obicons() { } } +void DreamGenContext::examineob() { + STACK_CHECK; + data.byte(kPointermode) = 0; + data.word(kTimecount) = 0; +examineagain: + data.byte(kInmaparea) = 0; + data.byte(kExamagain) = 0; + data.byte(kOpenedob) = 255; + data.byte(kOpenedtype) = 255; + data.byte(kInvopen) = 0; + al = data.byte(kCommandtype); + data.byte(kObjecttype) = al; + data.byte(kItemframe) = 0; + data.byte(kPointerframe) = 0; + createpanel(); + showpanel(); + showman(); + showexit(); + obicons(); + obpicture(); + describeob(); + undertextline(); + data.byte(kCommandtype) = 255; + readmouse(); + showpointer(); + worktoscreen(); + delpointer(); +waitexam: + readmouse(); + showpointer(); + vsync(); + dumppointer(); + dumptextline(); + delpointer(); + data.byte(kGetback) = 0; + bx = offset_examlist; + _cmp(data.byte(kInvopen), 0); + if (flags.z()) + goto notuseinv; + bx = offset_invlist1; + _cmp(data.byte(kInvopen), 1); + if (flags.z()) + goto notuseinv; + bx = offset_withlist1; +notuseinv: + checkcoords(); + _cmp(data.byte(kQuitrequested), 0); + if (!flags.z()) + goto stopwaiting; + _cmp(data.byte(kExamagain), 0); + if (flags.z()) + goto norex; + goto examineagain; +norex: + _cmp(data.byte(kGetback), 0); + if (flags.z()) + goto waitexam; +stopwaiting: + data.byte(kPickup) = 0; + _cmp(data.word(kWatchingtime), 0); + if (!flags.z()) + goto iswatching; + _cmp(data.byte(kNewlocation), 255); + if (!flags.z()) + goto justgetback; +iswatching: + makemainscreen(); + data.byte(kInvopen) = 0; + data.byte(kOpenedob) = 255; + return; +justgetback: + data.byte(kInvopen) = 0; + data.byte(kOpenedob) = 255; +} + + } /*namespace dreamgen */ |
