From 5a7dc8a733b3e607de8db2d833fea6d8b49d59a1 Mon Sep 17 00:00:00 2001 From: SmallJoker Date: Sun, 10 Aug 2014 11:19:31 +0200 Subject: [PATCH] Add default.flags to detect functions/features of the current game --- mods/default/init.lua | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/mods/default/init.lua b/mods/default/init.lua index 7c3d077d..ff16886e 100644 --- a/mods/default/init.lua +++ b/mods/default/init.lua @@ -45,3 +45,32 @@ dofile(minetest.get_modpath("default").."/mapgen.lua") dofile(minetest.get_modpath("default").."/player.lua") dofile(minetest.get_modpath("default").."/trees.lua") dofile(minetest.get_modpath("default").."/aliases.lua") + +-- Flags to detect functions/features of the current game + +default.features = { + -- Alias for default:* + ["alias"] = true, + -- Contains default.gui_* variables + ["gui"] = true, + --[[ Ores + 0 = exists minimal, lump and/or ingot only + 1 = exists with blocks + 2 = also generated as ore + ]] + ["coal"] = 2, + ["iron"] = 2, + ["copper"] = 2, + ["diamond"] = 2, + ["mese"] = 2, + ["gold"] = 1, + ["bronze"] = 1, + -- Normal trees + ["tree_normal"] = true, + -- Jungle trees + ["tree_jungle"] = true, + -- Grow tree without transfer of VM + ["new_grow_function"] = true, + ["papyrus"] = true, + ["cactus"] = true, +} \ No newline at end of file