aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2019-06-23 19:43:33 +0200
committerEugene Sandulenko2019-09-03 17:16:58 +0200
commit727c0b81adcd9fc1812c48cc16a027356cb69235 (patch)
treed14c7ad8a7119570c089c256c88b15c5543a4377
parentf3bfdf42958f77a360e019cf54cd83d0f7f5d4d3 (diff)
downloadscummvm-rg350-727c0b81adcd9fc1812c48cc16a027356cb69235.tar.gz
scummvm-rg350-727c0b81adcd9fc1812c48cc16a027356cb69235.tar.bz2
scummvm-rg350-727c0b81adcd9fc1812c48cc16a027356cb69235.zip
HDB: More debug output for entity drawing
-rw-r--r--engines/hdb/ai-funcs.cpp4
-rw-r--r--engines/hdb/ai-init.cpp94
-rw-r--r--engines/hdb/ai.h1
3 files changed, 97 insertions, 2 deletions
diff --git a/engines/hdb/ai-funcs.cpp b/engines/hdb/ai-funcs.cpp
index a04af9a677..cfbe16670d 100644
--- a/engines/hdb/ai-funcs.cpp
+++ b/engines/hdb/ai-funcs.cpp
@@ -1081,7 +1081,7 @@ void AI::animEntFrames(AIEntity *e) {
max = e->special1Frames;
break;
default:
- warning("AI-FUNCS: animEntFrames: Unintended State");
+ warning("AI-FUNCS: animEntFrames: Unintended State for entity %s", AIType2Str(e->type));
break;
}
@@ -1130,7 +1130,7 @@ void AI::drawEnts(int x, int y, int w, int h) {
for (Common::Array<AIEntity *>::iterator it = _ents->begin(); it != _ents->end(); it++) {
AIEntity *e = (*it);
- debugN(5, "AI::drawEnts: enity %s(%d)...", AIType2Str(e->type), e->type);
+ debugN(5, "AI::drawEnts: enity %s(%d) state %s(%d)...", AIType2Str(e->type), e->type, AIState2Str(e->state), e->state);
if (e->type == AI_LASER || e->type == AI_DIVERTER) {
if (e->aiDraw) {
diff --git a/engines/hdb/ai-init.cpp b/engines/hdb/ai-init.cpp
index 201c8fa05a..8f4ed860ec 100644
--- a/engines/hdb/ai-init.cpp
+++ b/engines/hdb/ai-init.cpp
@@ -1088,4 +1088,98 @@ const char *AIType2Str(AIType v) {
return AITypeStr[v];
}
+const char *AIStateStr[] = {
+ "STATE_NONE",
+ "STATE_STANDDOWN",
+ "STATE_STANDUP",
+ "STATE_STANDLEFT",
+ "STATE_STANDRIGHT",
+ "STATE_BLINK",
+ "STATE_MOVEUP",
+ "STATE_MOVEDOWN",
+ "STATE_MOVELEFT",
+ "STATE_MOVERIGHT",
+ "STATE_DYING",
+ "STATE_DEAD",
+ "STATE_HORRIBLE1",
+ "STATE_HORRIBLE2",
+ "STATE_HORRIBLE3",
+ "STATE_HORRIBLE4",
+ "STATE_GOODJOB",
+ "STATE_PLUMMET",
+
+ "STATE_PUSHUP",
+ "STATE_PUSHDOWN",
+ "STATE_PUSHLEFT",
+ "STATE_PUSHRIGHT",
+ "STATE_GRABUP",
+ "STATE_GRABDOWN",
+ "STATE_GRABLEFT",
+ "STATE_GRABRIGHT",
+ "STATE_ATK_CLUB_UP",
+ "STATE_ATK_CLUB_DOWN",
+ "STATE_ATK_CLUB_LEFT",
+ "STATE_ATK_CLUB_RIGHT",
+ "STATE_ATK_STUN_DOWN",
+ "STATE_ATK_STUN_UP",
+ "STATE_ATK_STUN_LEFT",
+ "STATE_ATK_STUN_RIGHT",
+ "STATE_ATK_SLUG_DOWN",
+ "STATE_ATK_SLUG_UP",
+ "STATE_ATK_SLUG_LEFT",
+ "STATE_ATK_SLUG_RIGHT",
+
+ "STATE_FLOATING",
+ "STATE_FLOATDOWN",
+ "STATE_FLOATUP",
+ "STATE_FLOATLEFT",
+ "STATE_FLOATRIGHT",
+ "STATE_MELTED",
+ "STATE_SLIDING",
+ "STATE_SHOCKING",
+ "STATE_EXPLODING",
+
+ "STATE_USEDOWN",
+ "STATE_USEUP",
+ "STATE_USELEFT",
+ "STATE_USERIGHT",
+
+ "STATE_MEER_MOVE",
+ "STATE_MEER_APPEAR",
+ "STATE_MEER_BITE",
+ "STATE_MEER_DISAPPEAR",
+ "STATE_MEER_LOOK",
+
+ "STATE_ICEP_PEEK",
+ "STATE_ICEP_APPEAR",
+ "STATE_ICEP_THROWDOWN",
+ "STATE_ICEP_THROWRIGHT",
+ "STATE_ICEP_THROWLEFT",
+ "STATE_ICEP_DISAPPEAR",
+
+ "STATE_LICKDOWN",
+ "STATE_LICKLEFT",
+ "STATE_LICKRIGHT",
+
+ "STATE_DIVERTER_BL",
+ "STATE_DIVERTER_BR",
+ "STATE_DIVERTER_TL",
+ "STATE_DIVERTER_TR",
+
+ "STATE_KISSRIGHT",
+ "STATE_KISSLEFT",
+ "STATE_ANGRY",
+ "STATE_PANIC",
+ "STATE_LAUGH",
+ "STATE_DOLLYUSERIGHT",
+
+ "STATE_YELL",
+
+ "STATE_ENDSTATES"
+};
+
+const char *AIState2Str(AIState v) {
+ return AIStateStr[v];
+}
+
} // End of Namespace
diff --git a/engines/hdb/ai.h b/engines/hdb/ai.h
index db0869f0fd..03d0b5ea30 100644
--- a/engines/hdb/ai.h
+++ b/engines/hdb/ai.h
@@ -953,6 +953,7 @@ private:
};
const char *AIType2Str(AIType v);
+const char *AIState2Str(AIState v);
} // End of Namespace