world creation and generators menus moved to xml

This commit is contained in:
MihailRis
2024-04-19 05:34:02 +03:00
parent ef4294ab47
commit 4f299be681
15 changed files with 187 additions and 136 deletions
@@ -0,0 +1,16 @@
settings = session.get_entry('new_world')
function on_open()
local names = core.get_generators()
table.sort(names)
local panel = document.root
for _,k in ipairs(names) do
panel:add(gui.template("generator", {
callback=string.format("settings.generator=%q menu:back()", k),
id=k,
name=settings.generator_name(k)
}))
end
panel:add("<button padding='10' onclick='menu:back()'>@Back</button>")
end