diff options
author | Nipun Garg | 2019-06-27 07:41:28 +0530 |
---|---|---|
committer | Eugene Sandulenko | 2019-09-03 17:17:02 +0200 |
commit | 86f7991eba8787a4e65758edd389982efbc749b0 (patch) | |
tree | 74a05aafb0e2a8bc91b418da5d5044120d85661c | |
parent | c0db320111fc666076239efa4bff48babef1511b (diff) | |
download | scummvm-rg350-86f7991eba8787a4e65758edd389982efbc749b0.tar.gz scummvm-rg350-86f7991eba8787a4e65758edd389982efbc749b0.tar.bz2 scummvm-rg350-86f7991eba8787a4e65758edd389982efbc749b0.zip |
HDB: Add _luaList data
-rw-r--r-- | engines/hdb/ai-init.cpp | 7 | ||||
-rw-r--r-- | engines/hdb/ai.h | 14 |
2 files changed, 21 insertions, 0 deletions
diff --git a/engines/hdb/ai-init.cpp b/engines/hdb/ai-init.cpp index ab25f2d7eb..989454cffd 100644 --- a/engines/hdb/ai-init.cpp +++ b/engines/hdb/ai-init.cpp @@ -843,6 +843,13 @@ void AI::restartSystem() { // Clear the Entity List _ents->clear(); + // Clear the Floats List + _floats->clear(); + + // Clear the Lua List + memset(_luaList, 0, sizeof(_luaList)); + _numLuaList = 0; + // Clear Anim Targets List _animTargets->clear(); diff --git a/engines/hdb/ai.h b/engines/hdb/ai.h index 3fb7945b9b..c76b6d6307 100644 --- a/engines/hdb/ai.h +++ b/engines/hdb/ai.h @@ -38,6 +38,7 @@ enum { kMaxActions = 20, kMaxTeleporters = 20, kMaxAutoActions = 30, + kMaxLuaEnts = 50, kPlayerMoveSpeed = 4, kEnemyMoveSpeed = 2, kPushMoveSpeed = (kPlayerMoveSpeed >> 1), @@ -564,6 +565,16 @@ struct Waypoint { Waypoint() : x(0), y(0), level(0) {} }; +struct LuaT { + uint16 x, y; + uint16 value1, value2; + char luaFuncInit[32]; + char luaFuncAction[32]; + char luaFuncUse[32]; + + LuaT() : x(0), y(0), value1(0), value2(0), luaFuncInit(""), luaFuncAction(""), luaFuncUse("") {} +}; + struct ActionInfo { uint16 x1, y1; uint16 x2, y2; @@ -1009,6 +1020,9 @@ public: Tile *_waypointGfx[4]; // Animating waypoint gfx Tile *_debugQMark; + LuaT _luaList[kMaxLuaEnts]; + int _numLuaList; + ActionInfo _actions[kMaxActions]; TeleInfo _teleporters[kMaxTeleporters]; |