diff options
author | Bertrand Augereau | 2011-11-17 15:08:34 +0100 |
---|---|---|
committer | Bertrand Augereau | 2011-11-17 15:23:12 +0100 |
commit | a389f1e46e7ceee0958c6d4c83c22bfd3afc87ee (patch) | |
tree | ce684e57317e81407bcfdca6c977470187f12968 /engines | |
parent | 3e049c0123a1af97b5f5372e2ab9496d5455ad26 (diff) | |
download | scummvm-rg350-a389f1e46e7ceee0958c6d4c83c22bfd3afc87ee.tar.gz scummvm-rg350-a389f1e46e7ceee0958c6d4c83c22bfd3afc87ee.tar.bz2 scummvm-rg350-a389f1e46e7ceee0958c6d4c83c22bfd3afc87ee.zip |
DREAMWEB: 'oldtonames' and 'namestoold' ported to C++
Diffstat (limited to 'engines')
-rw-r--r-- | engines/dreamweb/dreamgen.cpp | 22 | ||||
-rw-r--r-- | engines/dreamweb/dreamgen.h | 12 | ||||
-rw-r--r-- | engines/dreamweb/saveload.cpp | 7 | ||||
-rw-r--r-- | engines/dreamweb/stubs.h | 2 |
4 files changed, 14 insertions, 29 deletions
diff --git a/engines/dreamweb/dreamgen.cpp b/engines/dreamweb/dreamgen.cpp index 8f88560f7f..073e7c2310 100644 --- a/engines/dreamweb/dreamgen.cpp +++ b/engines/dreamweb/dreamgen.cpp @@ -12217,26 +12217,6 @@ afterprintname: goto shownameloop; } -void DreamGenContext::namestoold() { - STACK_CHECK; - ds = cs; - si = 8579; - di = (0+(228*13)+32+60+(32*32)+(11*10*3)+768+768+768+(32*32)+(128*5)+(80*5)+(100*5)+(12*5)); - es = data.word(kBuffers); - cx = 17*4; - _movsb(cx, true); -} - -void DreamGenContext::oldtonames() { - STACK_CHECK; - es = cs; - di = 8579; - si = (0+(228*13)+32+60+(32*32)+(11*10*3)+768+768+768+(32*32)+(128*5)+(80*5)+(100*5)+(12*5)); - ds = data.word(kBuffers); - cx = 17*4; - _movsb(cx, true); -} - void DreamGenContext::saveposition() { STACK_CHECK; makeheader(); @@ -16061,8 +16041,6 @@ void DreamGenContext::__dispatch_call(uint16 addr) { case addr_shownames: shownames(); break; case addr_dosreturn: dosreturn(); break; case addr_error: error(); break; - case addr_namestoold: namestoold(); break; - case addr_oldtonames: oldtonames(); break; case addr_savefilewrite: savefilewrite(); break; case addr_savefileread: savefileread(); break; case addr_saveposition: saveposition(); break; diff --git a/engines/dreamweb/dreamgen.h b/engines/dreamweb/dreamgen.h index a89fb435b3..f031fd6334 100644 --- a/engines/dreamweb/dreamgen.h +++ b/engines/dreamweb/dreamgen.h @@ -169,8 +169,6 @@ public: static const uint16 addr_saveposition = 0xc898; static const uint16 addr_savefileread = 0xc894; static const uint16 addr_savefilewrite = 0xc890; - static const uint16 addr_oldtonames = 0xc88c; - static const uint16 addr_namestoold = 0xc888; static const uint16 addr_error = 0xc884; static const uint16 addr_generalerror = 0xcbbc; static const uint16 addr_dosreturn = 0xc880; @@ -1295,7 +1293,7 @@ public: void showsaveops(); void intromonks1(); void resetlocation(); - void oldtonames(); + //void oldtonames(); void showdiscops(); void advisor(); void additionaltext(); @@ -1358,7 +1356,7 @@ public: void showsymbol(); void endgameseq(); //void cancelch0(); - void setbotleft(); + void turnonpower(); void findfirstpath(); //void cancelch1(); void loadold(); @@ -1368,7 +1366,7 @@ public: //void aboutturn(); void usealtar(); void createpanel2(); - void turnonpower(); + void setbotleft(); void manasleep2(); void moretalk(); //void printslow(); @@ -1648,7 +1646,7 @@ public: void deleverything(); void fadescreendown(); //void findxyfrompath(); - void namestoold(); + void poolguard(); //void getxad(); void openinv(); void lookatplace(); @@ -1668,7 +1666,7 @@ public: void loadintotemp3(); void loadintotemp2(); void gamer(); - void poolguard(); + //void namestoold(); void readfromfile(); void initialinv(); void quitsymbol(); diff --git a/engines/dreamweb/saveload.cpp b/engines/dreamweb/saveload.cpp index 02a128837b..6faab5554f 100644 --- a/engines/dreamweb/saveload.cpp +++ b/engines/dreamweb/saveload.cpp @@ -352,5 +352,12 @@ void DreamGenContext::savegame() { } } +void DreamGenContext::namestoold() { + memcpy(segRef(data.word(kBuffers)).ptr(kZoomspace, 0), cs.ptr(kSavenames, 0), 17*4); +} + +void DreamGenContext::oldtonames() { + memcpy(cs.ptr(kSavenames, 0), segRef(data.word(kBuffers)).ptr(kZoomspace, 0), 17*4); +} } /*namespace dreamgen */ diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h index ce54e27066..8769716efa 100644 --- a/engines/dreamweb/stubs.h +++ b/engines/dreamweb/stubs.h @@ -62,6 +62,8 @@ void getnumber(); uint8 getnumber(const Frame *charSet, const uint8 *string, uint16 maxWidth, bool centered, uint16 *offset); uint8 kernchars(uint8 firstChar, uint8 secondChar, uint8 width); + void oldtonames(); + void namestoold(); void getroomdata(); Room *getroomdata(uint8 room); void readheader(); |