Skip to content
Snippets Groups Projects
Commit 86bbbd66 authored by Chris N's avatar Chris N
Browse files

Dev Branch Created

Here there be drag- I mean bugs.
parent d310d2a1
No related branches found
No related tags found
No related merge requests found
......@@ -23,7 +23,7 @@ end
--generation settings
setting("number", "ymin", -33000) --bottom realm limit
setting("number", "ymax", -700) --top realm limit
setting("number", "chuint", 2) --vertical chunk interval between caves
setting("number", "chuint", 4) --vertical chunk interval between caves
--falling icicles
setting("bool", "falling_icicles", true) --enable/disable falling icicles
......
-- caverealms 0.2.8 by HeroOfTheWinds
-- caverealms 0.2.9 by HeroOfTheWinds
-- For latest stable Minetest and back to 0.4.8
-- Depends default
-- License: code WTFPL
......@@ -104,9 +104,7 @@ minetest.register_on_generated(function(minp, maxp, seed)
--determine if there's enough spacing between layers to start a realm
local chulay = math.floor((minp.y + 32) / 80) -- chunk layer number, 0 = surface chunk
if math.fmod(chulay, CHUINT) ~= 0 then -- if chulay / CHUINT has a remainder
return
end
local tercen = (math.floor(chulay / CHUINT) * CHUINT + CHUINT / 2) * 80 - 32 -- terrain centre of this layer
--easy to reference variables for limits and time
local t1 = os.clock()
......@@ -192,7 +190,7 @@ minetest.register_on_generated(function(minp, maxp, seed)
for x = x0, x1 do -- for each node do
--here's the good part
local si = x - x0 + 1 --stability index
local cavemid = chumid + nvals_wave[nixz] * WAVAMP --grab the middle of the cave's amplitude
local cavemid = tercen + nvals_wave[nixz] * WAVAMP --grab the middle of the cave's amplitude
local grad
if y > cavemid then
grad = ((y - cavemid) / HISCAL) ^ HIEXP --for the ceiling
......@@ -298,7 +296,7 @@ minetest.register_on_generated(function(minp, maxp, seed)
for x = x0, x1 do -- for each node do
--here's the good part
local si = x - x0 + 1 --stability index
local cavemid = chumid + nvals_wave[nixz2] * WAVAMP --grab the middle of the cave's amplitude
local cavemid = tercen + nvals_wave[nixz2] * WAVAMP --grab the middle of the cave's amplitude
local grad
if y > cavemid then
grad = ((y - cavemid) / HISCAL) ^ HIEXP --for the ceiling
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment