aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/hdb/ai-funcs.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/engines/hdb/ai-funcs.cpp b/engines/hdb/ai-funcs.cpp
index 2592861e08..22c8040c8f 100644
--- a/engines/hdb/ai-funcs.cpp
+++ b/engines/hdb/ai-funcs.cpp
@@ -25,7 +25,11 @@
namespace HDB {
AIEntity *AI::locateEntity(const char *luaName) {
- warning("STUB: AI::locateEntity required");
+ for (Common::Array<AIEntity *>::iterator it = _ents->begin(); it != _ents->end(); it++) {
+ if (Common::matchString((*it)->entityName, luaName)) {
+ return *it;
+ }
+ }
return NULL;
}