aboutsummaryrefslogtreecommitdiff
path: root/engines/hdb/lua-script.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/hdb/lua-script.cpp')
-rw-r--r--engines/hdb/lua-script.cpp22
1 files changed, 21 insertions, 1 deletions
diff --git a/engines/hdb/lua-script.cpp b/engines/hdb/lua-script.cpp
index bffb7856d2..e4d5f0efe7 100644
--- a/engines/hdb/lua-script.cpp
+++ b/engines/hdb/lua-script.cpp
@@ -362,7 +362,27 @@ static int cineMoveMaskedPic(lua_State *L) {
}
static int cineSpawnEntity(lua_State *L) {
- warning("STUB: CINE SPAWN ENTITY");
+ double type = lua_tonumber( L, 1 );
+ double dir = lua_tonumber( L, 2 );
+ double x = lua_tonumber( L, 3 );
+ double y = lua_tonumber( L, 4 );
+ const char *func_init = lua_tostring( L, 5 );
+ const char *func_action = lua_tostring( L, 6 );
+ const char *func_use = lua_tostring( L, 7 );
+ double dir2 = lua_tonumber( L, 8 );
+ double level = lua_tonumber( L, 9 );
+ double value1 = lua_tonumber( L, 10 );
+ double value2 = lua_tonumber( L, 11 );
+
+ int t = (int) type;
+ int d = (int) dir;
+ int d2 = (int) dir2;
+
+ g_hdb->_lua->checkParameters("Cine_SpawnEntity", 11);
+
+ lua_pop(L, 11);
+ g_hdb->_ai->cineSpawnEntity((AIType)t, (AIDir)d, (int)x, (int)y, func_init, func_action, func_use,
+ (AIDir)d2, (int)level, (int)value1, (int)value2);
return 0;
}