aboutsummaryrefslogtreecommitdiff
path: root/engines/fullpipe
diff options
context:
space:
mode:
authorEugene Sandulenko2017-12-08 20:29:30 +0000
committerEugene Sandulenko2017-12-08 23:57:48 +0100
commitc728c29857d12ddc039a2982b9bd510ed6a9f620 (patch)
treea1aa7c09c808e0116a4627483b8fca9483ee4b56 /engines/fullpipe
parent39385589f691ea3f13281158754180c5aedded64 (diff)
downloadscummvm-rg350-c728c29857d12ddc039a2982b9bd510ed6a9f620.tar.gz
scummvm-rg350-c728c29857d12ddc039a2982b9bd510ed6a9f620.tar.bz2
scummvm-rg350-c728c29857d12ddc039a2982b9bd510ed6a9f620.zip
FULLPIPE: More debug output to loading
Diffstat (limited to 'engines/fullpipe')
-rw-r--r--engines/fullpipe/fullpipe.cpp1
-rw-r--r--engines/fullpipe/fullpipe.h3
-rw-r--r--engines/fullpipe/gfx.cpp3
-rw-r--r--engines/fullpipe/messages.cpp4
-rw-r--r--engines/fullpipe/scenes/scene32.cpp2
-rw-r--r--engines/fullpipe/statics.cpp26
-rw-r--r--engines/fullpipe/statics.h4
7 files changed, 37 insertions, 6 deletions
diff --git a/engines/fullpipe/fullpipe.cpp b/engines/fullpipe/fullpipe.cpp
index ec2b5aa71d..fef896d663 100644
--- a/engines/fullpipe/fullpipe.cpp
+++ b/engines/fullpipe/fullpipe.cpp
@@ -67,6 +67,7 @@ FullpipeEngine::FullpipeEngine(OSystem *syst, const ADGameDescription *gameDesc)
DebugMan.addDebugChannel(kDebugInventory, "inventory", "Inventory");
DebugMan.addDebugChannel(kDebugSceneLogic, "scenelogic", "Scene Logic");
DebugMan.addDebugChannel(kDebugInteractions, "interactions", "Interactions");
+ DebugMan.addDebugChannel(kDebugXML, "xml", "XML");
// Setup mixer
if (!_mixer->isReady()) {
diff --git a/engines/fullpipe/fullpipe.h b/engines/fullpipe/fullpipe.h
index 2039989c91..08c6de2621 100644
--- a/engines/fullpipe/fullpipe.h
+++ b/engines/fullpipe/fullpipe.h
@@ -59,7 +59,8 @@ enum {
kDebugBehavior = 1 << 6,
kDebugInventory = 1 << 7,
kDebugSceneLogic = 1 << 8,
- kDebugInteractions = 1 << 9
+ kDebugInteractions = 1 << 9,
+ kDebugXML = 1 << 10
};
class BehaviorManager;
diff --git a/engines/fullpipe/gfx.cpp b/engines/fullpipe/gfx.cpp
index a2626e28ea..667c2ba190 100644
--- a/engines/fullpipe/gfx.cpp
+++ b/engines/fullpipe/gfx.cpp
@@ -463,7 +463,8 @@ bool Picture::load(MfcArchive &file) {
getData();
- debugC(5, kDebugLoading, "Picture::load: loaded <%s>", _memfilename.c_str());
+ debugC(5, kDebugLoading, "Picture::load: loaded memobject=\"%s\" x=%d y=%d f44=%d width=%d height=%d alpha=%d memobject2=\"%s\"", _memfilename.c_str(),
+ _x, _y, _field_44, _width, _height, _alpha, _memoryObject2->_memfilename.c_str());
return true;
}
diff --git a/engines/fullpipe/messages.cpp b/engines/fullpipe/messages.cpp
index 7c69ae8a0f..0272e82f58 100644
--- a/engines/fullpipe/messages.cpp
+++ b/engines/fullpipe/messages.cpp
@@ -107,7 +107,7 @@ bool ExCommand::load(MfcArchive &file) {
_objtype = kObjTypeExCommand;
- debugC(6, kDebugLoading, "%% <COMMAND parent=%d cmd=%s x=%d y=%d f14=%d sceneX=%d sceneY=%d f20=%d f24=%d param=%d f2c=%d f30=%d f34=%d num=%d flags=%d parId=%d />",
+ debugC(6, kDebugXML, "%% <COMMAND parent=%d cmd=%s x=%d y=%d f14=%d sceneX=%d sceneY=%d f20=%d f24=%d param=%d f2c=%d f30=%d f34=%d num=%d flags=%d parId=%d />",
_parentId, exCommandType2str(_messageKind), _x, _y, _z, _sceneClickX, _sceneClickY, _field_20, _field_24, _param, _field_2C,
_field_30, _field_34, _messageNum, _excFlags, _parId);
@@ -240,7 +240,7 @@ bool ObjstateCommand::load(MfcArchive &file) {
_objCommandName = file.readPascalString();
- debugC(6, kDebugLoading, "%% <COMMAND cmd=\"USER\" type=\"SET_LOGIC\" title=\"%s\" state=\"%d\" />", transCyrillic(_objCommandName.c_str()), _value);
+ debugC(6, kDebugXML, "%% <COMMAND cmd=\"USER\" type=\"SET_LOGIC\" title=\"%s\" state=\"%d\" />", transCyrillic(_objCommandName.c_str()), _value);
return true;
}
diff --git a/engines/fullpipe/scenes/scene32.cpp b/engines/fullpipe/scenes/scene32.cpp
index 593f7b446c..d4b4a6527f 100644
--- a/engines/fullpipe/scenes/scene32.cpp
+++ b/engines/fullpipe/scenes/scene32.cpp
@@ -91,6 +91,8 @@ void scene32_initScene(Scene *sc) {
g_fp->lift_init(sc, QU_SC32_ENTERLIFT, QU_SC32_EXITLIFT);
g_fp->initArcadeKeys("SC_32");
+
+ warning("cactus: %d, state: %d", g_fp->getObjectState(sO_Cactus), g_vars->scene32_cactus->_statics->_staticsId);
}
void scene32_setupMusic() {
diff --git a/engines/fullpipe/statics.cpp b/engines/fullpipe/statics.cpp
index a1252a75af..b5baa180fa 100644
--- a/engines/fullpipe/statics.cpp
+++ b/engines/fullpipe/statics.cpp
@@ -163,6 +163,9 @@ bool StaticANIObject::load(MfcArchive &file) {
GameObject::load(file);
+ debugC(6, kDebugXML, "%% <OLDANI id=%d name=\"%s\" x=%d y=%d priority=%d f8=%d>",
+ _id, transCyrillic(_objectName), _ox, _oy, _priority, _field_8);
+
int count = file.readUint16LE();
for (int i = 0; i < count; i++) {
@@ -197,6 +200,8 @@ bool StaticANIObject::load(MfcArchive &file) {
pt.x = pt.y = 100;
}
+ debugC(6, kDebugXML, "%% </OLDANI>");
+
setOXY(pt.x, pt.y);
return true;
@@ -1371,7 +1376,8 @@ bool Statics::load(MfcArchive &file) {
_staticsId = file.readUint16LE();
_staticsName = file.readPascalString();
- debugC(7, kDebugLoading, "statics: <%s> id: %d (%x)", transCyrillic(_staticsName), _staticsId, _staticsId);
+ debugC(6, kDebugXML, "%% <STATICS id=%d name=\"%s\" f7c=%d %s />",
+ _staticsId, transCyrillic(_staticsName), _field_7C, DynamicPhase::toXML().c_str());
_picture.load(file);
@@ -1573,7 +1579,9 @@ bool Movement::load(MfcArchive &file, StaticANIObject *ani) {
int dynCount = file.readUint16LE();
- debugC(7, kDebugLoading, "dynCount: %d _id: %d", dynCount, _id);
+ debugC(6, kDebugXML, "%% <MOVEMENT id=%d name=\"%s\" x=%d y=%d priority=%d f8=%d>",
+ _id, transCyrillic(_objectName), _ox, _oy, _priority, _field_8);
+
if (dynCount != 0xffff || _id == MV_MAN_TURN_LU) {
_framePosOffsets.resize(dynCount + 2);
@@ -1581,6 +1589,8 @@ bool Movement::load(MfcArchive &file, StaticANIObject *ani) {
DynamicPhase *ph = new DynamicPhase();
ph->load(file);
+ debugC(6, kDebugXML, "%% <PHASE %s />", ph->toXML().c_str());
+
_dynamicPhases.push_back(ph);
_framePosOffsets[i].x = ph->_x;
@@ -1644,6 +1654,8 @@ bool Movement::load(MfcArchive &file, StaticANIObject *ani) {
_counter = 0;
updateCurrDynamicPhase();
+ debugC(6, kDebugXML, "%% </MOVEMENT>");
+
return true;
}
@@ -2127,6 +2139,12 @@ DynamicPhase::DynamicPhase(DynamicPhase *src, bool reverse) {
copyMemoryObject2(*src);
}
+Common::String DynamicPhase::toXML() {
+ return Common::String::format("f7c=%d left=%d top=%d right=%d bottom=%d sX=%d sY=%d dynFlags=%d %s",
+ _field_7C, _rect.left, _rect.top, _rect.right, _rect.bottom, _someX, _someY, _dynFlags,
+ StaticPhase::toXML().c_str());
+}
+
bool DynamicPhase::load(MfcArchive &file) {
debugC(5, kDebugLoading, "DynamicPhase::load()");
@@ -2157,6 +2175,10 @@ StaticPhase::StaticPhase() {
_field_68 = 0;
}
+Common::String StaticPhase::toXML() {
+ return Common::String::format("countdown=%d f6a=%d", _initialCountdown, _field_6A);
+}
+
bool StaticPhase::load(MfcArchive &file) {
debugC(5, kDebugLoading, "StaticPhase::load()");
diff --git a/engines/fullpipe/statics.h b/engines/fullpipe/statics.h
index b0e083e212..770d431bd8 100644
--- a/engines/fullpipe/statics.h
+++ b/engines/fullpipe/statics.h
@@ -60,6 +60,8 @@ class StaticPhase : public Picture {
virtual bool load(MfcArchive &file);
+ virtual Common::String toXML();
+
ExCommand *getExCommand() { return _exCommand.get(); }
};
@@ -78,6 +80,8 @@ class DynamicPhase : public StaticPhase {
virtual bool load(MfcArchive &file);
+ virtual Common::String toXML();
+
int getDynFlags() { return _dynFlags; }
};