aboutsummaryrefslogtreecommitdiff
path: root/engines/hdb/lua-script.cpp
diff options
context:
space:
mode:
authorEugene Sandulenko2019-07-03 14:55:25 +0200
committerEugene Sandulenko2019-09-03 17:17:09 +0200
commit106a63aa81a17d9598936785b55d80641d6432de (patch)
treeacd8e16b8720fff99ce8193b7e7d5464581dd03f /engines/hdb/lua-script.cpp
parent734995512e354af0dac3ee5681372f283c7d375e (diff)
downloadscummvm-rg350-106a63aa81a17d9598936785b55d80641d6432de.tar.gz
scummvm-rg350-106a63aa81a17d9598936785b55d80641d6432de.tar.bz2
scummvm-rg350-106a63aa81a17d9598936785b55d80641d6432de.zip
HDB: Add LASTMAPNAME Lua variable
Diffstat (limited to 'engines/hdb/lua-script.cpp')
-rw-r--r--engines/hdb/lua-script.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/engines/hdb/lua-script.cpp b/engines/hdb/lua-script.cpp
index a42ca79857..8e7083b653 100644
--- a/engines/hdb/lua-script.cpp
+++ b/engines/hdb/lua-script.cpp
@@ -1346,10 +1346,9 @@ bool LuaScript::initScript(Common::SeekableReadStream *stream, const char *scrip
lua_setglobal(_state, luaGlobalValues[j].luaName);
}
- /*
- TODO: Set the last mapName as a global
- after implementing the map-manager.
- */
+ // set the last mapname as a global
+ lua_pushstring(_state, g_hdb->lastMapname());
+ lua_setglobal(_state, "LASTMAP");
// Set the lowest printable line
lua_pushnumber(_state, 480 - 14);