diff --git a/dists/engine-data/patches/grim/si.lua.patchr b/dists/engine-data/patches/grim/si.lua.patchr new file mode 100644 index 0000000000..dda06838aa --- /dev/null +++ b/dists/engine-data/patches/grim/si.lua.patchr @@ -0,0 +1,13 @@ +PATCHR 1 + +# In the function si.set_up_actors (line 848), calls "start_script(si.naranja_drinking)", +# which doesn't exist. +# The problem with that is that lua_error ends the function that was going on, +# breaking si.set really badly. + +begin 826b0f8e65bf5818ca64a29a37e65c0a 8CC4 #Both v1.0 and v1.01 + +#Just replace the bad call with NOP +replace 4959 FF FF FF FF FF FF FF FF + +end diff --git a/dists/engine-data/residualvm-grim-patch.lab b/dists/engine-data/residualvm-grim-patch.lab index 4e41afb0ca..b96e7b2f81 100644 Binary files a/dists/engine-data/residualvm-grim-patch.lab and b/dists/engine-data/residualvm-grim-patch.lab differ diff --git a/engines/grim/lua/ltask.cpp b/engines/grim/lua/ltask.cpp index c3d143ea00..186e2467ab 100644 --- a/engines/grim/lua/ltask.cpp +++ b/engines/grim/lua/ltask.cpp @@ -38,13 +38,7 @@ void start_script() { lua_Type type = ttype(Address(paramObj)); if (paramObj == LUA_NOOBJECT || (type != LUA_T_CPROTO && type != LUA_T_PROTO)) { - warning("lua: Bad argument to start_script. - lua/ltask.cpp:32"); - // NOTE: Decomment the lua_error if you want to see the stacktrace. - // It is commented out because si.lua, in the function si.set_up_actors (line 848), - // calls "start_script(si.naranja_drinking)", which doesn't exist. The problem with - // that is that lua_error ends the function that was going on, breaking - // si.set really badly. - // lua_error("Bad argument to start_script"); + lua_error("Bad argument to start_script"); return; }