summaryrefslogtreecommitdiff
path: root/caverealms/config.lua
diff options
context:
space:
mode:
authorVanessa Ezekowitz <vanessaezekowitz@gmail.com>2016-04-01 20:02:19 -0400
committerVanessa Ezekowitz <vanessaezekowitz@gmail.com>2016-04-01 21:09:33 -0400
commitda66780a569712c23ae4f2996cfb4608a9f9d69d (patch)
tree217556029a78bc23ad4564720afc86de97228a04 /caverealms/config.lua
parent615b22df4d423aded3613db7716943a2f389b047 (diff)
downloaddreambuilder_modpack-da66780a569712c23ae4f2996cfb4608a9f9d69d.tar
dreambuilder_modpack-da66780a569712c23ae4f2996cfb4608a9f9d69d.tar.gz
dreambuilder_modpack-da66780a569712c23ae4f2996cfb4608a9f9d69d.tar.bz2
dreambuilder_modpack-da66780a569712c23ae4f2996cfb4608a9f9d69d.tar.xz
dreambuilder_modpack-da66780a569712c23ae4f2996cfb4608a9f9d69d.zip
copy all standard Dreambuilder mods in from the old subgame
(exactly as last supplied there, updates to these mods will follow later)
Diffstat (limited to 'caverealms/config.lua')
-rw-r--r--caverealms/config.lua45
1 files changed, 45 insertions, 0 deletions
diff --git a/caverealms/config.lua b/caverealms/config.lua
new file mode 100644
index 0000000..15b23d0
--- /dev/null
+++ b/caverealms/config.lua
@@ -0,0 +1,45 @@
+
+local CONFIG_FILE_PREFIX = "caverealms."
+
+caverealms.config = {}
+
+-- This function based on kaeza/minetest-irc/config.lua and used under the
+-- terms of BSD 2-clause license.
+local function setting(stype, name, default)
+ local value
+ if stype == "bool" then
+ value = minetest.setting_getbool(CONFIG_FILE_PREFIX..name)
+ elseif stype == "string" then
+ value = minetest.setting_get(CONFIG_FILE_PREFIX..name)
+ elseif stype == "number" then
+ value = tonumber(minetest.setting_get(CONFIG_FILE_PREFIX..name))
+ end
+ if value == nil then
+ value = default
+ end
+ caverealms.config[name] = value
+end
+
+--generation settings
+setting("number", "ymin", -33000) --bottom realm limit
+setting("number", "ymax", -700) --top realm limit
+setting("number", "tcave", 0.5) --cave threshold
+
+--falling icicles
+setting("bool", "falling_icicles", true) --enable/disable falling icicles
+setting("number", "fallcha", 0.33) --chance of icicles falling when dug
+
+--decoration chances
+setting("number", "stagcha", 0.002) --chance of stalagmites
+setting("number", "stalcha", 0.003) --chance of stalactites
+setting("number", "h_lag", 15) --max height for stalagmites
+setting("number", "h_lac", 20) --...stalactites
+setting("number", "crystal", 0.007) --chance of glow crystal formations
+setting("number", "h_cry", 9) --max height of glow crystals
+setting("number", "h_clac", 13) --max height of glow crystal stalactites
+setting("number", "gemcha", 0.03) --chance of small glow gems
+setting("number", "mushcha", 0.04) --chance of mushrooms
+setting("number", "myccha", 0.03) --chance of mycena mushrooms
+setting("number", "wormcha", 0.02) --chance of glow worms
+setting("number", "giantcha", 0.001) --chance of giant mushrooms
+setting("number", "icicha", 0.035) --chance of icicles