Much better narration/dialogue/action handling (and for lua too)
This commit is contained in:
@@ -302,7 +302,10 @@ LuaData::LuaData()
|
||||
lua_setglobal(L, "setup_handler");
|
||||
lua_pushcfunction(L, [](lua_State *L) -> int {
|
||||
luaL_checktype(L, 1, LUA_TSTRING);
|
||||
luaL_checktype(L, 2, LUA_TFUNCTION);
|
||||
if (lua_type(L, 2) == LUA_TFUNCTION)
|
||||
luaL_checktype(L, 2, LUA_TFUNCTION);
|
||||
else
|
||||
luaL_checktype(L, 2, LUA_TTABLE);
|
||||
ECS::get_mut<PlayerActionModule>().setupLuaActionHandler(L);
|
||||
ECS::modified<PlayerActionModule>();
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user