aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
Diffstat (limited to 'engines')
-rw-r--r--engines/hdb/ai-funcs.cpp8
-rw-r--r--engines/hdb/ai.h2
2 files changed, 10 insertions, 0 deletions
diff --git a/engines/hdb/ai-funcs.cpp b/engines/hdb/ai-funcs.cpp
index 9bbcf9d329..1c25198e37 100644
--- a/engines/hdb/ai-funcs.cpp
+++ b/engines/hdb/ai-funcs.cpp
@@ -1015,6 +1015,14 @@ void AI::drawEnts(int x, int y, int w, int h) {
}
}
+bool AI::checkFloating(int x, int y) {
+ for (Common::Array<AIEntity *>::iterator it = _floats->begin(); it != _floats->end(); it++) {
+ if ((*it)->tileX == x && (*it)->tileY == y)
+ return true;
+ }
+ return false;
+}
+
// Check to see if we can get this entity
bool AI::getTableEnt(AIType type) {
switch (type) {
diff --git a/engines/hdb/ai.h b/engines/hdb/ai.h
index c29f1c8ad8..b6b9b4a612 100644
--- a/engines/hdb/ai.h
+++ b/engines/hdb/ai.h
@@ -565,6 +565,8 @@ public:
void animLuaEntity(const char *initName, AIState st);
void drawEnts(int x, int y, int w, int h);
+ bool checkFloating(int x, int y);
+
bool getTableEnt(AIType type);
bool walkThroughEnt(AIType type);
void getItemSound(AIType type);