1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-11-21 08:55:21 +01:00

Move keybinding settings to (Lua-based) setting menu (#15791)

This commit is contained in:
y5nw
2025-04-20 20:20:49 +02:00
committed by GitHub
parent c1d2124102
commit 23bfb2db72
25 changed files with 591 additions and 782 deletions

View File

@@ -35,11 +35,21 @@ int ModApiMenuCommon::l_irrlicht_device_supports_touch(lua_State *L)
}
int ModApiMenuCommon::l_are_keycodes_equal(lua_State *L)
{
auto k1 = luaL_checkstring(L, 1);
auto k2 = luaL_checkstring(L, 2);
lua_pushboolean(L, KeyPress(k1) == KeyPress(k2));
return 1;
}
void ModApiMenuCommon::Initialize(lua_State *L, int top)
{
API_FCT(gettext);
API_FCT(get_active_driver);
API_FCT(irrlicht_device_supports_touch);
API_FCT(are_keycodes_equal);
}