aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xdevtools/tasmrecover/tasm-recover1
-rw-r--r--engines/dreamweb/dreamgen.cpp27
-rw-r--r--engines/dreamweb/dreamgen.h1
-rw-r--r--engines/dreamweb/sprite.cpp15
4 files changed, 15 insertions, 29 deletions
diff --git a/devtools/tasmrecover/tasm-recover b/devtools/tasmrecover/tasm-recover
index 386e938e8b..63797c6e17 100755
--- a/devtools/tasmrecover/tasm-recover
+++ b/devtools/tasmrecover/tasm-recover
@@ -207,6 +207,7 @@ generator = cpp(context, "DreamGen", blacklist = [
'clearendpal',
'clearpalette',
'clearreels',
+ 'clearrest',
'clearsprites',
'clearstartpal',
'clearwork',
diff --git a/engines/dreamweb/dreamgen.cpp b/engines/dreamweb/dreamgen.cpp
index b54dc63858..d7669c60d4 100644
--- a/engines/dreamweb/dreamgen.cpp
+++ b/engines/dreamweb/dreamgen.cpp
@@ -7439,33 +7439,6 @@ void DreamGenContext::clearChanges() {
_stosw(cx, true);
}
-void DreamGenContext::clearRest() {
- STACK_CHECK;
- es = data.word(kMapdata);
- cx = (66*60)/2;
- ax = 0;
- di = (0);
- _stosw(cx, true);
- es = data.word(kBackdrop);
- deallocateMem();
- es = data.word(kSetframes);
- deallocateMem();
- es = data.word(kReels);
- deallocateMem();
- es = data.word(kPeople);
- deallocateMem();
- es = data.word(kSetdesc);
- deallocateMem();
- es = data.word(kBlockdesc);
- deallocateMem();
- es = data.word(kRoomdesc);
- deallocateMem();
- es = data.word(kFreeframes);
- deallocateMem();
- es = data.word(kFreedesc);
- deallocateMem();
-}
-
void DreamGenContext::watchReel() {
STACK_CHECK;
_cmp(data.word(kReeltowatch), -1);
diff --git a/engines/dreamweb/dreamgen.h b/engines/dreamweb/dreamgen.h
index 3b7b6fee89..98aab6e2c6 100644
--- a/engines/dreamweb/dreamgen.h
+++ b/engines/dreamweb/dreamgen.h
@@ -729,7 +729,6 @@ public:
void findExObject();
void searchForFiles();
void monkSpeaking();
- void clearRest();
void madmanRun();
void afterNewRoom();
void getExAd();
diff --git a/engines/dreamweb/sprite.cpp b/engines/dreamweb/sprite.cpp
index fd6d2dc9e8..9f3666312a 100644
--- a/engines/dreamweb/sprite.cpp
+++ b/engines/dreamweb/sprite.cpp
@@ -1165,7 +1165,20 @@ void DreamGenContext::clearBeforeLoad() {
return /* (noclear) */;
clearReels();
- clearRest();
+
+ //clearRest
+ uint8 *dst = (uint8 *)getSegment(data.word(kMapdata)).ptr(0, 0);
+ memset(dst, 0, kMaplen);
+ deallocateMem(data.word(kBackdrop));
+ deallocateMem(data.word(kSetframes));
+ deallocateMem(data.word(kReels));
+ deallocateMem(data.word(kPeople));
+ deallocateMem(data.word(kSetdesc));
+ deallocateMem(data.word(kBlockdesc));
+ deallocateMem(data.word(kRoomdesc));
+ deallocateMem(data.word(kFreeframes));
+ deallocateMem(data.word(kFreedesc));
+
data.byte(kRoomloaded) = 0;
}