aboutsummaryrefslogtreecommitdiff
path: root/engines/hdb/lua-script.cpp
diff options
context:
space:
mode:
authorNipun Garg2019-06-26 18:53:04 +0530
committerEugene Sandulenko2019-09-03 17:17:00 +0200
commita070e60617041a49a159706532b4169c35f56395 (patch)
tree60e9f1b9cdeba2b60d67f23427f3aadb5717a7a4 /engines/hdb/lua-script.cpp
parent578b063a9d391c0da6e6d1eacf67a0d703cfd17a (diff)
downloadscummvm-rg350-a070e60617041a49a159706532b4169c35f56395.tar.gz
scummvm-rg350-a070e60617041a49a159706532b4169c35f56395.tar.bz2
scummvm-rg350-a070e60617041a49a159706532b4169c35f56395.zip
HDB: Fix Lua stack indices
Diffstat (limited to 'engines/hdb/lua-script.cpp')
-rw-r--r--engines/hdb/lua-script.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/engines/hdb/lua-script.cpp b/engines/hdb/lua-script.cpp
index 62ad8d6f82..a4e4749a9f 100644
--- a/engines/hdb/lua-script.cpp
+++ b/engines/hdb/lua-script.cpp
@@ -258,7 +258,7 @@ static int cineMoveEntity(lua_State *L) {
static int cineAnimEntity(lua_State *L) {
const char *entName = lua_tostring(L, 1);
double state = lua_tonumber(L, 2);
- double loop = lua_tonumber(L, 2);
+ double loop = lua_tonumber(L, 3);
g_hdb->_lua->checkParameters("cineAnimEntity", 3);
@@ -271,7 +271,7 @@ static int cineAnimEntity(lua_State *L) {
static int cineSetAnimFrame(lua_State *L) {
const char *entName = lua_tostring(L, 1);
double state = lua_tonumber(L, 2);
- double frame = lua_tonumber(L, 2);
+ double frame = lua_tonumber(L, 3);
g_hdb->_lua->checkParameters("cineSetAnimFrame", 3);
@@ -338,7 +338,7 @@ static int cineSpawnEntity(lua_State *L) {
static int cineClearForeground(lua_State *L) {
double x = lua_tonumber(L, 1);
- double y = lua_tonumber(L, 1);
+ double y = lua_tonumber(L, 2);
g_hdb->_lua->checkParameters("cineClearForeground", 2);
@@ -349,7 +349,7 @@ static int cineClearForeground(lua_State *L) {
static int cineSetForeground(lua_State *L) {
double x = lua_tonumber(L, 1);
- double y = lua_tonumber(L, 1);
+ double y = lua_tonumber(L, 2);
const char *tileName = lua_tostring(L, 3);
g_hdb->_lua->checkParameters("cineSetForeground", 3);
@@ -363,7 +363,7 @@ static int cineSetForeground(lua_State *L) {
static int cineSetBackground(lua_State *L) {
double x = lua_tonumber(L, 1);
- double y = lua_tonumber(L, 1);
+ double y = lua_tonumber(L, 2);
const char *tileName = lua_tostring(L, 3);
g_hdb->_lua->checkParameters("cineSetBackground", 3);