mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-13 16:45:20 +02:00
38 lines
698 B
C++
38 lines
698 B
C++
// Luanti
|
|
// SPDX-License-Identifier: LGPL-2.1-or-later
|
|
// Copyright (C) 2025 grorp
|
|
|
|
#include "l_pause_menu.h"
|
|
#include "gui/mainmenumanager.h"
|
|
#include "lua_api/l_internal.h"
|
|
#include "client/client.h"
|
|
|
|
|
|
int ModApiPauseMenu::l_show_keys_menu(lua_State *L)
|
|
{
|
|
g_gamecallback->keyConfig();
|
|
return 0;
|
|
}
|
|
|
|
|
|
int ModApiPauseMenu::l_show_touchscreen_layout(lua_State *L)
|
|
{
|
|
g_gamecallback->touchscreenLayout();
|
|
return 0;
|
|
}
|
|
|
|
|
|
int ModApiPauseMenu::l_is_internal_server(lua_State *L)
|
|
{
|
|
lua_pushboolean(L, getClient(L)->m_internal_server);
|
|
return 1;
|
|
}
|
|
|
|
|
|
void ModApiPauseMenu::Initialize(lua_State *L, int top)
|
|
{
|
|
API_FCT(show_keys_menu);
|
|
API_FCT(show_touchscreen_layout);
|
|
API_FCT(is_internal_server);
|
|
}
|