summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTenPlus1 <kinsellaja@yahoo.com>2017-03-01 09:58:46 +0000
committerTenPlus1 <kinsellaja@yahoo.com>2017-03-01 09:58:46 +0000
commit66525a91a29b798c7ac707b3cf9c8d82a7b238b0 (patch)
tree70b3b30d0f01f0213c7d46b969ea6cd02da68c00
parenteca5b6e13c6b08bed05919425ed5a435f462b5f1 (diff)
Added support for "default:dirt_with_rainforest_litter"
-rw-r--r--README.md1
-rw-r--r--dirt.lua10
-rw-r--r--init.lua2
-rw-r--r--mapgen.lua37
-rw-r--r--plantpack.lua7
5 files changed, 33 insertions, 24 deletions
diff --git a/README.md b/README.md
index b639793..0adc5b4 100644
--- a/README.md
+++ b/README.md
@@ -19,6 +19,7 @@ Ethereal Mapgen mod for Minetest (works on all except v6)
- Added settings.conf file example so that settings remain after mod update
- Added support for Real Torch so that torches near water drop an unlit torch
- Added support for new leafdecay functions (0.4.15 dev)
+ - Mapgen will use dirt_with_rainforest_litter for jungles if found
### 1.21
diff --git a/dirt.lua b/dirt.lua
index e99f13a..08d9c4b 100644
--- a/dirt.lua
+++ b/dirt.lua
@@ -80,7 +80,8 @@ dirts = {
"ethereal:prairie_dirt", "ethereal:cold_dirt", "ethereal:crystal_dirt",
"ethereal:mushroom_dirt", "ethereal:fiery_dirt", "ethereal:gray_dirt",
"default:dirt_with_grass", "default:dirt_with_dry_grass", "ethereal:green_dirt",
- "default:dirt_with_snow", "default:dirt_with_dry_grass"
+ "default:dirt_with_snow", "default:dirt_with_dry_grass",
+ "default:dirt_with_rainforest_litter"
}
-- check surrounding grass and change dirt to same colour
@@ -107,8 +108,9 @@ local grass_spread = function(pos, node)
local positions, grasses = minetest.find_nodes_in_area(
{x = pos.x - 1, y = pos.y - 2, z = pos.z - 1},
{x = pos.x + 1, y = pos.y + 2, z = pos.z + 1},
- {"group:ethereal_grass", "default:dirt_with_grass",
- "default:dirt_with_dry_grass", "default:dirt_with_snow"})
+-- {"group:ethereal_grass", "default:dirt_with_grass",
+-- "default:dirt_with_dry_grass", "default:dirt_with_snow"})
+ dirts)
-- count new grass nodes
for n = 1, #dirts do
@@ -159,7 +161,7 @@ local flower_spread = function(pos, node)
local pos0 = {x = pos.x - 4, y = pos.y - 2, z = pos.z - 4}
local pos1 = {x = pos.x + 4, y = pos.y + 2, z = pos.z + 4}
- local num = #minetest.find_nodes_in_area_under_air(pos0, pos1, "group:flora")
+ local num = #minetest.find_nodes_in_area(pos0, pos1, "group:flora")
-- stop flowers spreading too much just below top of map block
if minetest.find_node_near(pos, 2, "ignore") then
diff --git a/init.lua b/init.lua
index 0bdecd9..af1eccb 100644
--- a/init.lua
+++ b/init.lua
@@ -1,6 +1,6 @@
--[[
- Minetest Ethereal Mod (28th February 2017)
+ Minetest Ethereal Mod (1st March 2017)
Created by ChinChow
diff --git a/mapgen.lua b/mapgen.lua
index 80b7bff..78e72a6 100644
--- a/mapgen.lua
+++ b/mapgen.lua
@@ -163,8 +163,13 @@ add_biome("jumble", nil, "ethereal:green_dirt", 1, "default:dirt", 3,
add_biome("jumble_ocean", nil, "default:sand", 1, "default:sand", 2,
nil, nil, nil, nil, nil, -192, 1, 25, 50, ethereal.jumble)
-add_biome("junglee", nil, "ethereal:jungle_dirt", 1, "default:dirt", 3,
- nil, nil, nil, nil, nil, 1, 71, 30, 60, ethereal.junglee)
+if minetest.registered_nodes["default:dirt_with_rainforest_litter"] then
+ add_biome("junglee", nil, "default:dirt_with_rainforest_litter", 1, "default:dirt", 3,
+ nil, nil, nil, nil, nil, 1, 71, 30, 60, ethereal.junglee)
+else
+ add_biome("junglee", nil, "ethereal:jungle_dirt", 1, "default:dirt", 3,
+ nil, nil, nil, nil, nil, 1, 71, 30, 60, ethereal.junglee)
+end
add_biome("junglee_ocean", nil, "default:sand", 1, "default:sand", 2,
nil, nil, nil, nil, nil, -192, 1, 30, 60, ethereal.junglee)
@@ -259,7 +264,7 @@ add_schem({"ethereal:fiery_dirt"}, 0.01, {"fiery"}, 1, 100, path .. "volcanom.mt
add_schem({"ethereal:fiery_dirt"}, 0.01, {"fiery"}, 1, 100, path .. "volcanol.mts", ethereal.fiery)
-- default jungle tree
-add_schem({"ethereal:jungle_dirt"}, 0.08, {"junglee"}, 1, 100, dpath .. "jungle_tree.mts", ethereal.junglee)
+add_schem({"ethereal:jungle_dirt", "default:dirt_with_rainforest_litter"}, 0.08, {"junglee"}, 1, 100, dpath .. "jungle_tree.mts", ethereal.junglee)
-- willow tree
add_schem({"ethereal:gray_dirt"}, 0.02, {"grayness"}, 1, 100, path .. "willow.mts", ethereal.grayness)
@@ -400,12 +405,12 @@ add_node({"default:desert_sand"}, 0.005, {"desert"}, 1, 100, {"default:cactus"},
add_node({"ethereal:mushroom_dirt"}, 0.01, {"mushroom"}, 1, 100, {"flowers:mushroom_fertile_red"}, nil, nil, nil, ethereal.mushroom)
local list = {
- {"junglee", "ethereal:jungle_dirt", ethereal.junglee},
- {"grassy", "ethereal:green_dirt", ethereal.grassy},
- {"grassytwo", "ethereal:green_dirt", ethereal.grassytwo},
- {"prairie", "ethereal:prairie_dirt", ethereal.prairie},
- {"mushroom", "ethereal:mushroom_dirt", ethereal.mushroom},
- {"swamp", "ethereal:green_dirt", ethereal.swamp},
+ {"junglee", {"ethereal:jungle_dirt", "default:dirt_with_rainforest_litter"}, ethereal.junglee},
+ {"grassy", {"ethereal:green_dirt"}, ethereal.grassy},
+ {"grassytwo", {"ethereal:green_dirt"}, ethereal.grassytwo},
+ {"prairie", {"ethereal:prairie_dirt"}, ethereal.prairie},
+ {"mushroom", {"ethereal:mushroom_dirt"}, ethereal.mushroom},
+ {"swamp", {"ethereal:green_dirt"}, ethereal.swamp},
}
-- wild red and brown mushrooms
@@ -414,7 +419,7 @@ for _, row in pairs(list) do
if row[3] == 1 then
minetest.register_decoration({
deco_type = "simple",
- place_on = {row[2]},
+ place_on = row[2],
sidelen = 16,
noise_params = {
offset = 0,
@@ -434,7 +439,7 @@ end
end
-- jungle grass
-add_node({"ethereal:jungle_dirt"}, 0.10, {"junglee"}, 1, 100, {"default:junglegrass"}, nil, nil, nil, ethereal.junglee)
+add_node({"ethereal:jungle_dirt", "default:dirt_with_rainforest_litter"}, 0.10, {"junglee"}, 1, 100, {"default:junglegrass"}, nil, nil, nil, ethereal.junglee)
add_node({"ethereal:green_dirt"}, 0.15, {"jumble"}, 1, 100, {"default:junglegrass"}, nil, nil, nil, ethereal.jumble)
add_node({"ethereal:green_dirt"}, 0.25, {"swamp"}, 1, 100, {"default:junglegrass"}, nil, nil, nil, ethereal.swamp)
@@ -445,7 +450,7 @@ add_node({"ethereal:green_dirt"}, 0.35, {"grassytwo"}, 1, 100, {"default:grass_2
"default:grass_4", "default:grass_5"}, nil, nil, nil, ethereal.grassytwo)
add_node({"ethereal:green_dirt"}, 0.35, {"jumble"}, 1, 100, {"default:grass_2", "default:grass_3",
"default:grass_4", "default:grass_5"}, nil, nil, nil, ethereal.jumble)
-add_node({"ethereal:jungle_dirt"}, 0.35, {"junglee"}, 1, 100, {"default:grass_2", "default:grass_3",
+add_node({"ethereal:jungle_dirt", "default:dirt_with_rainforest_litter"}, 0.35, {"junglee"}, 1, 100, {"default:grass_2", "default:grass_3",
"default:grass_4", "default:grass_5"}, nil, nil, nil, ethereal.junglee)
add_node({"ethereal:prairie_dirt"}, 0.35, {"prairie"}, 1, 100, {"default:grass_2", "default:grass_3",
"default:grass_4", "default:grass_5"}, nil, nil, nil, ethereal.prairie)
@@ -475,7 +480,7 @@ add_node({"ethereal:prairie_dirt"}, 0.25, {"prairie"}, 1, 100, {"ethereal:onion_
-- papyrus
add_node({"ethereal:green_dirt"}, 0.1, {"grassy"}, 1, 1, {"default:papyrus"}, 4, "default:water_source", 1, ethereal.grassy)
-add_node({"ethereal:jungle_dirt"}, 0.1, {"junglee"}, 1, 1, {"default:papyrus"}, 4, "default:water_source", 1, ethereal.junglee)
+add_node({"ethereal:jungle_dirt", "default:dirt_with_rainforest_litter"}, 0.1, {"junglee"}, 1, 1, {"default:papyrus"}, 4, "default:water_source", 1, ethereal.junglee)
add_node({"ethereal:green_dirt"}, 0.1, {"swamp"}, 1, 1, {"default:papyrus"}, 4, "default:water_source", 1, ethereal.swamp)
--= Farming Redo plants
@@ -485,7 +490,7 @@ if farming and farming.mod and farming.mod == "redo" then
print ("[MOD] Ethereal - Farming Redo detected and in use")
-- potato
-add_node({"ethereal:jungle_dirt"}, 0.035, {"junglee"}, 1, 100, {"farming:potato_3"}, nil, nil, nil, ethereal.junglee)
+add_node({"ethereal:jungle_dirt", "default:dirt_with_rainforest_litter"}, 0.035, {"junglee"}, 1, 100, {"farming:potato_3"}, nil, nil, nil, ethereal.junglee)
-- carrot, cucumber, potato, tomato, corn, coffee, raspberry, rhubarb
add_node({"ethereal:green_dirt"}, 0.05, {"grassytwo"}, 1, 100, {"farming:carrot_7", "farming:cucumber_4",
@@ -502,7 +507,7 @@ add_node({"ethereal:prairie_dirt"}, 0.05, {"prairie"}, 1, 100, {"farming:carrot_
"farming:raspberry_4", "farming:rhubarb_3", "farming:blueberry_4"}, nil, nil, nil, ethereal.prairie)
-- melon and pumpkin
-add_node({"ethereal:jungle_dirt"}, 0.015, {"junglee"}, 1, 1, {"farming:melon_8", "farming:pumpkin_8"}, nil, "default:water_source", 1, ethereal.junglee)
+add_node({"ethereal:jungle_dirt", "default:dirt_with_rainforest_litter"}, 0.015, {"junglee"}, 1, 1, {"farming:melon_8", "farming:pumpkin_8"}, nil, "default:water_source", 1, ethereal.junglee)
add_node({"ethereal:green_dirt"}, 0.015, {"grassy"}, 1, 1, {"farming:melon_8", "farming:pumpkin_8"}, nil, "default:water_source", 1, ethereal.grassy)
add_node({"ethereal:green_dirt"}, 0.015, {"grassytwo"}, 1, 1, {"farming:melon_8", "farming:pumpkin_8"}, nil, "default:water_source", 1, ethereal.grassytwo)
add_node({"ethereal:green_dirt"}, 0.015, {"jumble"}, 1, 1, {"farming:melon_8", "farming:pumpkin_8"}, nil, "default:water_source", 1, ethereal.jumble)
@@ -662,7 +667,7 @@ minetest.register_decoration({
minetest.register_decoration({
deco_type = "simple",
- place_on = {"ethereal:jungle_dirt"},
+ place_on = {"ethereal:jungle_dirt", "default:dirt_with_rainforest_litter"},
sidelen = 16,
noise_params = {
offset = 0,
diff --git a/plantpack.lua b/plantpack.lua
index 517e1c2..03e1096 100644
--- a/plantpack.lua
+++ b/plantpack.lua
@@ -81,7 +81,7 @@ minetest.register_decoration({
place_on = {
"ethereal:prairie_grass", "ethereal:green_dirt",
"ethereal:grove_dirt", "ethereal:jungle_grass",
- "ethereal:gray_dirt"
+ "ethereal:gray_dirt", "default:dirt_with_rainforest_litter"
},
sidelen = 16,
fill_ratio = 0.005,
@@ -96,7 +96,7 @@ minetest.register_decoration({
minetest.register_decoration({
deco_type = "simple",
- place_on = {"ethereal:jungle_dirt", "ethereal:green_dirt"},
+ place_on = {"ethereal:jungle_dirt", "ethereal:green_dirt", "default:dirt_with_rainforest_litter"},
sidelen = 16,
fill_ratio = 0.007,
biomes = {"junglee", "jumble"},
@@ -166,7 +166,8 @@ minetest.register_decoration({
"ethereal:dirt_with_snow", "ethereal:jungle_dirt",
"ethereal:prairie_dirt", "ethereal:grove_dirt",
"ethereal:dry_dirt", "ethereal:fiery_dirt", "default:sand",
- "default:desert_sand", "xanadu:red", "ethereal:bamboo_dirt"
+ "default:desert_sand", "xanadu:red", "ethereal:bamboo_dirt",
+ "default:dirt_with_rainforest_litter"
},
sidelen = 16,
fill_ratio = 0.004,