mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-12 06:21:50 +00:00
add gui.close_menu
This commit is contained in:
parent
239ada8e3d
commit
965faebc7b
2 changed files with 8 additions and 1 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
<panel size='400' color='0' interval='1' context='menu'>
|
<panel size='400' color='0' interval='1' context='menu'>
|
||||||
<button onclick='menu:reset()'>@Continue</button>
|
<button onclick='gui.close_menu()'>@Continue</button>
|
||||||
<button onclick='menu.page="content?mode=world"'>@Content</button>
|
<button onclick='menu.page="content?mode=world"'>@Content</button>
|
||||||
<button onclick='menu.page="settings"'>@Settings</button>
|
<button onclick='menu.page="settings"'>@Settings</button>
|
||||||
<button onclick='app.close_world(true)'>
|
<button onclick='app.close_world(true)'>
|
||||||
|
|
|
||||||
|
|
@ -234,6 +234,13 @@ menu = _MENU
|
||||||
gui.root = _GUI_ROOT
|
gui.root = _GUI_ROOT
|
||||||
gui.main_frame_id = "core:main"
|
gui.main_frame_id = "core:main"
|
||||||
|
|
||||||
|
function gui.close_menu()
|
||||||
|
if menu then
|
||||||
|
menu:reset()
|
||||||
|
end
|
||||||
|
gui.set_active_frame("")
|
||||||
|
end
|
||||||
|
|
||||||
local __gui_create_frame = gui.create_frame
|
local __gui_create_frame = gui.create_frame
|
||||||
function gui.create_frame(id, output, size)
|
function gui.create_frame(id, output, size)
|
||||||
__gui_create_frame(id, output, size)
|
__gui_create_frame(id, output, size)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue