diff --git a/src/mapgen_v6.lua b/src/mapgen_v6.lua index be528ab..6486192 100644 --- a/src/mapgen_v6.lua +++ b/src/mapgen_v6.lua @@ -36,27 +36,11 @@ local function do_ws_func(a, x) local n = x/(16000) local y = 0 for k=1,1000 do - y = y + 1000*(math.sin(math.pi * k^a * n)/(math.pi * k^a)) + y = y + 1000*math.sin(math.pi * k^a * n)/(math.pi * k^a) end return y end -local ws_lists = {} -local function get_ws_list(a,x) - ws_lists[a] = ws_lists[a] or {} - local v = ws_lists[a][x] - if v then - return v - end - v = {} - for x=x,x + (80 - 1) do - local y = do_ws_func(a, x) - v[x] = y - end - ws_lists[a][x] = v - return v -end - local plantlike_ids = {} local function is_plantlike(id) @@ -365,11 +349,7 @@ minetest.register_on_generated(function(minp, maxp, seed) if test > 0 then local maxh = math.floor(test*10)%10+1 if maxh ~= 1 then - if not wsz then - wsz = get_ws_list(5, z0) - wsx = get_ws_list(2, x0) - end - local h = math.floor(wsx[x]+wsz[z]*5)%10+1 + local h = math.floor( do_ws_func(2, x) + do_ws_func(5, z)*5)%10+1 if h ~= 1 then -- search for nearby snow y = y+1 diff --git a/src/nodes.lua b/src/nodes.lua index 260c5d4..5d05c25 100644 --- a/src/nodes.lua +++ b/src/nodes.lua @@ -157,6 +157,7 @@ minetest.register_node("snow:moss", { }, is_ground_content = true, groups = {crumbly=3, attached_node=1}, + furnace_burntime = 3, }) -- Shrub(s) @@ -178,6 +179,7 @@ nodedef = { type = "fixed", fixed = {-0.3, -0.5, -0.3, 0.3, -5/16, 0.3}, }, + furnace_burntime = 5, } minetest.register_node("snow:shrub", table.copy(nodedef)) @@ -185,6 +187,7 @@ nodedef.tiles = {"snow_shrub.png^snow_shrub_covering.png"} nodedef.inventory_image = "snow_shrub.png^snow_shrub_covering.png" nodedef.wield_image = "snow_shrub.png^snow_shrub_covering.png" nodedef.drop = "snow:shrub" +nodedef.furnace_burntime = 3 minetest.register_node("snow:shrub_covered", nodedef)