aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFilippos Karapetis2011-12-26 22:47:14 +0200
committerFilippos Karapetis2011-12-26 22:47:14 +0200
commita75d39895b882a2bcc1b6469b1e75265bab2ac6c (patch)
tree0304c57f828510f6a53d0833c0394b674c6437fe
parentfb074000869310cbc949deeb14d8380aa0f93e0d (diff)
downloadscummvm-rg350-a75d39895b882a2bcc1b6469b1e75265bab2ac6c.tar.gz
scummvm-rg350-a75d39895b882a2bcc1b6469b1e75265bab2ac6c.tar.bz2
scummvm-rg350-a75d39895b882a2bcc1b6469b1e75265bab2ac6c.zip
DREAMWEB: Move some functions to DreamBase, remove dead code
-rw-r--r--engines/dreamweb/dreambase.h7
-rw-r--r--engines/dreamweb/monitor.cpp4
-rw-r--r--engines/dreamweb/object.cpp4
-rw-r--r--engines/dreamweb/stubs.cpp10
-rw-r--r--engines/dreamweb/stubs.h21
5 files changed, 14 insertions, 32 deletions
diff --git a/engines/dreamweb/dreambase.h b/engines/dreamweb/dreambase.h
index c17a15e34a..1502e391fa 100644
--- a/engines/dreamweb/dreambase.h
+++ b/engines/dreamweb/dreambase.h
@@ -595,6 +595,13 @@ public:
void errorMessage2();
void errorMessage3();
void decide();
+ void allPointer();
+ void dumpWatch();
+ void watchCount();
+ void signOn();
+ void searchForFiles(uint16 segment);
+ void triggerMessage(uint16 index);
+ void processTrigger();
// from talk.cpp
void talk();
diff --git a/engines/dreamweb/monitor.cpp b/engines/dreamweb/monitor.cpp
index 0caf4b7c25..db3401e078 100644
--- a/engines/dreamweb/monitor.cpp
+++ b/engines/dreamweb/monitor.cpp
@@ -551,7 +551,7 @@ void DreamGenContext::read() {
}
}
-void DreamGenContext::signOn() {
+void DreamBase::signOn() {
const char *name = parser();
int8 foundIndex = -1;
@@ -609,7 +609,7 @@ void DreamGenContext::signOn() {
}
}
-void DreamGenContext::searchForFiles(uint16 segment) {
+void DreamBase::searchForFiles(uint16 segment) {
const char *filesString = (const char *)getSegment(segment).ptr(kTextstart, 0);
byte curChar;
diff --git a/engines/dreamweb/object.cpp b/engines/dreamweb/object.cpp
index 4fa21e7618..31a5af0bb5 100644
--- a/engines/dreamweb/object.cpp
+++ b/engines/dreamweb/object.cpp
@@ -78,10 +78,6 @@ void DreamBase::makeWorn(DynObject *object) {
object->id[1] = 'E'-'A';
}
-void DreamGenContext::obToInv() {
- obToInv(al, ah, di, bx);
-}
-
void DreamBase::obToInv(uint8 index, uint8 flag, uint16 x, uint16 y) {
showFrame(engine->icons1(), x - 2, y - 1, 10, 0);
if (index == 0xff)
diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp
index ca98337261..c8aac95e72 100644
--- a/engines/dreamweb/stubs.cpp
+++ b/engines/dreamweb/stubs.cpp
@@ -842,7 +842,7 @@ void DreamBase::putUnderTimed() {
multiPut(_underTimedText, data.byte(kTimedx), data.byte(kTimedy), 240, kUnderTimedTextSizeY);
}
-void DreamGenContext::triggerMessage(uint16 index) {
+void DreamBase::triggerMessage(uint16 index) {
multiGet(mapStore(), 174, 153, 200, 63);
uint16 offset = kTextstart + getSegment(data.word(kPuzzletext)).word(index * 2);
const uint8 *string = getSegment(data.word(kPuzzletext)).ptr(offset, 0);
@@ -856,7 +856,7 @@ void DreamGenContext::triggerMessage(uint16 index) {
data.byte(kLasttrigger) = 0;
}
-void DreamGenContext::processTrigger() {
+void DreamBase::processTrigger() {
if (data.byte(kLasttrigger) == '1') {
setLocation(8);
triggerMessage(45);
@@ -1937,7 +1937,7 @@ void DreamBase::showWatch() {
}
}
-void DreamGenContext::dumpWatch() {
+void DreamBase::dumpWatch() {
if (data.byte(kWatchdump) != 1)
return;
multiDump(256, 21, 40, 12);
@@ -1965,7 +1965,7 @@ void DreamBase::showTime() {
showFrame(charset, 267+5, 21, 91*3+20, 0);
}
-void DreamGenContext::watchCount() {
+void DreamBase::watchCount() {
if (data.byte(kWatchon) == 0)
return;
++data.byte(kTimercount);
@@ -2785,7 +2785,7 @@ void DreamBase::blank() {
}
}
-void DreamGenContext::allPointer() {
+void DreamBase::allPointer() {
readMouse();
showPointer();
dumpPointer();
diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h
index 3536b7d07c..24a7c081b5 100644
--- a/engines/dreamweb/stubs.h
+++ b/engines/dreamweb/stubs.h
@@ -47,30 +47,15 @@
bool checkIfPerson(uint8 x, uint8 y);
bool checkIfFree(uint8 x, uint8 y);
bool checkIfEx(uint8 x, uint8 y);
- DynObject *getFreeAd(uint8 index) {
- return DreamBase::getFreeAd(index);
- }
- DynObject *getExAd(uint8 index) {
- return DreamBase::getExAd(index);
- }
- void *getAnyAd(uint8 *slotSize, uint8 *slotCount) {
- return DreamBase::getAnyAd(slotSize, slotCount);
- }
- SetObject *getSetAd(uint8 index) {
- return DreamBase::getSetAd(index);
- }
void walkAndExamine();
void obName(uint8 command, uint8 commandType);
bool checkIfSet(uint8 x, uint8 y);
- void obToInv();
void obToInv(uint8 index, uint8 flag, uint16 x, uint16 y) {
DreamBase::obToInv(index, flag, x, y);
}
void useRoutine();
void examineOb(bool examineAgain = true);
- void dumpWatch();
- void watchCount();
void readSetData();
void useMon();
void makeCaps();
@@ -94,24 +79,18 @@
void doLook();
void useKey();
void useObject();
- void singleKey(uint8 key, uint16 x, uint16 y);
void inventory();
void mainScreen();
void zoomOnOff();
void initialInv();
void walkIntoRoom();
- void allPointer();
void afterNewRoom();
void madmanRun();
void showGun();
- void triggerMessage(uint16 index);
- void processTrigger();
bool execCommand();
void identifyOb();
void selectOb();
void getKeyAndLogo();
- void signOn();
- void searchForFiles(uint16 segment);
void read();
void dirCom();