mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Merge 7d075d4fcb
into fdc149f316
This commit is contained in:
commit
a542f91a3e
2 changed files with 9 additions and 2 deletions
|
@ -80,7 +80,7 @@ local mgv6_biomes = {
|
|||
|
||||
local function create_world_formspec(dialogdata)
|
||||
|
||||
local current_mg = dialogdata.mg
|
||||
local current_mg = dialogdata.mg or core.settings:get("mg_name")
|
||||
local mapgens = core.get_mapgen_names()
|
||||
|
||||
local flags = dialogdata.flags
|
||||
|
@ -96,6 +96,11 @@ local function create_world_formspec(dialogdata)
|
|||
if game ~= nil then
|
||||
local gameconfig = Settings(game.path.."/game.conf")
|
||||
|
||||
local game_default_mg = gameconfig:get("default_mapgen")
|
||||
if dialogdata.mg == nil and game_default_mg then
|
||||
current_mg = game_default_mg
|
||||
end
|
||||
|
||||
local allowed_mapgens = (gameconfig:get("allowed_mapgens") or ""):split()
|
||||
for key, value in pairs(allowed_mapgens) do
|
||||
allowed_mapgens[key] = value:trim()
|
||||
|
@ -456,7 +461,6 @@ function create_create_world_dlg()
|
|||
worldname = "",
|
||||
-- settings the world is created with:
|
||||
seed = core.settings:get("fixed_map_seed") or "",
|
||||
mg = core.settings:get("mg_name"),
|
||||
flags = {
|
||||
main = core.settings:get_flags("mg_flags"),
|
||||
v5 = core.settings:get_flags("mgv5_spflags"),
|
||||
|
|
|
@ -84,6 +84,9 @@ The game directory can contain the following files:
|
|||
When both `allowed_mapgens` and `disallowed_mapgens` are
|
||||
specified, `allowed_mapgens` is applied before
|
||||
`disallowed_mapgens`.
|
||||
* `default_mapgen`
|
||||
e.g. `default_mapgen = valleys`
|
||||
Set default mapgen for game, this will be the default selection when creating a new world.
|
||||
* `disallowed_mapgen_settings= <comma-separated mapgen settings>`
|
||||
e.g. `disallowed_mapgen_settings = mgv5_spflags`
|
||||
These mapgen settings are hidden for this game in the world creation
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue