HDB: Set the Entity Spawn names in Lua

This commit is contained in:
Nipun Garg 2019-06-19 17:06:29 +05:30 committed by Eugene Sandulenko
parent 81d6064430
commit 3437261133

View File

@ -730,7 +730,13 @@ bool LuaScript::initScript(Common::SeekableReadStream *stream, const char *scrip
spawn names into Lua once they are implemented.
*/
warning("STUB: LuaScript::initScript: Load ai_all_ents");
// Set the Entity Spawn Names in Lua
int j = 0;
while (aiEntList[j].luaName) {
lua_pushnumber(_state, aiEntList[j].type);
lua_setglobal(_state, aiEntList[j].luaName);
j++;
}
// Register panic callback function
lua_atpanic(_state, panicCB);