#46 Fixes oranges and bananas don't grow

Closed
Xachman wants to merge 1 commits from Xachman/add_ethereal_mod_for_bananas_oranges into NathanS21/master

BIN
master.zip


+ 378 - 0
mods/ethereal/README.md

@@ -0,0 +1,378 @@
+# ethereal
+
+Ethereal Mapgen mod for Minetest (works on all except v6)
+
+## Forum Topic
+- https://forum.minetest.net/viewtopic.php?f=11&t=14638
+
+## Lucky Blocks
+42
+
+## Changelog
+
+### 1.27
+
+ - Added Etherium ore and dust
+ - Added sparse decoration of dry grass and shrub to caves biome
+ - Added sponges that spawn near coral, dry sponge in furnace to soak up water
+ - Added new savanna dirt and decorations
+ - Use default grass abms
+ - Split and re-write mapgen files for tidier generation
+
+### 1.26
+
+ - Added Sakura biome, pink sakura trees and saplings
+ - 1 in 10 chance of sakura sapling growing into white sakura
+ - Bamboo grows in higher elevation while sakura grows in lower
+ - Added sakura wood, stairs, fence, gate and door
+ - Added 5.0 checks to add new biomes and decorations
+ - Fixed water abm for dry dirt and added check for minetest 5.1 dry dirt also
+
+### 1.25
+
+ - Converted .mts files into schematic tables for easier editing
+ - Added firethorn shrub in glacier areas (can be crafted into jelly)
+ - Tweaked mapgen decorations
+ - Added more lucky blocks
+ - Added igloo to glacier biome
+ - 2x2 bamboo = bamboo floor, 3x3 bamboo or 2x bamboo floor = bamboo block, blocks can be made into sticks, bamboo stairs need blocks to craft
+
+### 1.24
+
+ - Updating code to newer functions, requires Minetest 0.4.16 and above
+ - Added food groups to be more compatible with other food mods
+ - Bonemeal removed (use Bonemeal mod to replace https://forum.minetest.net/viewtopic.php?f=9&t=16446 )
+ - Crystal Ingot recipe requires a bucket of water, unless you are using builtin_item mod where you can mix ingredients by dropping in a pool of water instead
+
+### 1.23
+
+ - Added bonemeal support for bush sapling and acacia bush sapling
+ - Added support for [toolranks] mod if found
+ - Reworked Crystal Shovel so it acts more like a normal shovel with soft touch
+
+### 1.22
+
+ - Added coral and silver sand to mapgen (0.4.15 only)
+ - Replaced ethereal:green_dirt with default:dirt_with_grass for mortrees compatibility
+ - Mesa biomes are now topped with dirt with dry grass (redwood saplings grow on dry grass)
+ - Added bonemeal support for moretree's saplings
+ - 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
+ - Added bushes to mapgen
+
+### 1.21
+
+ - Saplings need clear space above to grow (depending on height of tree)
+ - Bonemeal changes to suit new sapling growth
+ - Fixes and tweaks
+ - Added default Abm overrides
+ - Added 4 new plants from baked clay mod to mapgen
+ - Added swamp biome to outskirts of bamboo areas
+
+### 1.20
+
+- Tweaked Ethereal to work with new features and nodes in Minetest 0.4.14
+- Added bones found in dirt and bonemeal to make tree's and crops grow quicker
+- Tree's follow default rules where saplings need light to grow
+- Using default schematics for apple, pine, acacia and jungle tree's
+- Tidied and split code into separate files
+- Redid coloured grass spread function to run better
+- Added support for moreblock's stairsplus feature
+
+### 1.19
+
+- Added new biome routine to help restructure biomes
+- Tweaked biome values so that they are more spread out (no more huge bamboo biome)
+- Tweaked biome plant and tree decorations
+- Fixed farming compatibility when using hoe on ethereal dirt
+- Dirt with dry grass turns into green grass when near water
+- Ice or snow above sea level melts into river water
+- Disabling ethereal biomes no longer shows error messages
+- Fire Flowers re-generate, can also be made into Fire Dust and both are fuel
+- Optimize and tidy code
+
+### 1.18
+
+- Added Birch tree, also stairs; fence and gate
+- Added Fire flower to fiery biomes (careful, it hurts)
+- Tweaked biomes and decoration slightly
+- Added tree_tool for admin to quickly grow tree's
+- Cobble to Mossycobble when near water has been toned down a bit
+
+### 1.17
+
+- Added new Glacier biome filled with snow and ice
+- Changed Mesa biome to have more coloured clay patterns
+- Changed Bamboo biome to have tall tree-like stalks with leaves that give
+- Bamboo sprouts are now saplings to grow new stalks
+- Removed farmed mushrooms and replaced with default game mushrooms with spores
+
+### 1.16
+
+- Added new tree schematics that change when placed with random leaves, fruit and height
+- Changed frost dirt so that it no longer freezes water (saves lag)
+- Torches cannot be placed next to water, otherwise they drop as items
+- Added latest farming redo Bean Bushes to mapgen
+- Code tidy (thanks HybridDog) and bug fix
+- Banana, Orange and Apple fruits now drop when tree has been removed.
+
+### 1.15
+
+- Added Staff of Light (thanks Xanthin), crafted from illumishrooms and can turn stone into glostone and back again
+- Changed how Crystal Spikes reproduce
+- Crystal Ingots now require 2x mese crystal and 2x crystal spikes to craft
+- Removed obsidian brick & stairs now they are in default game, also removed pine wood stairs for same reason
+- Tidied code and optimized a few routines
+
+
+### 1.14
+
+- Changed Ethereal to work with Minetest 0.4.11 update and new mapgen features
+- Changed Pine tree's to use default pine wood
+- Added pine wood fence, gate and stairs
+- Crystal Spikes now re-generate in crystal biomes
+- Removed layer mapgen, keeping spread as default
+
+
+### 1.13
+
+- Changed melting feature to work with 0.4.11 pre-release now that group:hot and group:melt have been removed
+
+
+### 1.12
+
+- Added ability to disable biomes in the init.lua file by setting to 1 (enable) or 0 (disable)
+- Supports Framing Redo 1.10 foods
+
+
+### 1.11
+
+- Added Stairs for Ethereal wood types, mushroom, dry dirt, obsidian brick and clay
+- Added Green Coral which can be used as green dye
+- Craft 5x Ice in X pattern to give 5x Snow
+- Added Snow and Ice Bricks with their own stairs and slabs which melt when near heat
+
+
+### 1.10
+
+- Added Stone Ladders (another use for cobble)
+- Craft 5x Gravel in X pattern to give 5 dirt, and 5x dirt in X pattern for 5 sand
+- Added Acacia tree's to desert biome (a nice pink wood to build with, thanks to VanessaE for textures)
+- Added Acacia fences and gates
+- Added Vines, craftable with 2x3 leaves
+
+
+### 1.09
+
+- Fixed Quicksand bug where player see's only black when sinking instead of yellow effect, note this will only work on new maps or newly generated areas of map containing quicksand
+- Hot nodes will melt ice and snow in a better way
+- Few spelling errors sorted for sapling and wood names
+
+
+### 1.08
+
+- Saplings produce better placed tree's when grown, routines have been redone
+- Orange tree's now spawn in prairie biomes
+- The usual code tidy and few bug fixes along the way
+
+### 1.07
+
+- If Farming Redo mod detected then it's growing routines will be used for Ethereal plantlife instead of default
+Leaftype and Mapstyle settings can be changed within init.lua file, new layered style maps are being tested
+Changed crafting recipe for Fences, they tie in with Gates a little better
+
+### 1.06
+
+- Added support for Farming Redo mod, all plants spawn on newly generated areas:
+ - https://forum.minetest.net/viewtopic.php?id=9019
+
+### 1.05b
+
+- Added Gates for each of the fence types (thanks to Blockmen for gate model)
+- Players can no longer jump over fences unless they wear crystal boots < REMOVED
+
+### 1.04
+
+- Farming of Mushrooms, Wild Onions and Strawberries now use minetest 0.4.10 functions
+- Strawberries can be grown by using actual fruit, seeds no longer needed
+- Tree leaves are no longer walkable, player can go through them
+- Saplings now fall if block underneath disturbed
+
+### 1.03
+
+- Changed Fence recipe's so it doesn't interfere with 3d armor's wooden boots
+- Tweaked textures to bring down file sizes
+- Flowers, Sprouts and Ferns now spread over ALL grassland
+
+### 1.02
+
+- Fences added for each type of wood in Ethereal
+- Changes to biome settings, less artifacts
+
+### 1.01
+
+- Quicksand generates throughout world near sandy water
+- Bamboo as well as Papyrus now grow on dirt near water
+- Fixed Coral textures and light
+
+### 1.00
+
+- Seaweed now spawns in deep water and can grow up to 10 high
+- Coral also spawns in deep water and glows slightly (orange, pink and blue)
+- Above items can be crafted into dye, also Seaweed is edible
+- So long as sand isn't disturbed under the ocean, sealife will re-generate
+- Fixed Leaves inventory images and Mushroom selection box (thanks Wuzzy)
+
+### 0.0.9
+#### 0.0.9p
+
+- Willow Trees now spawn in grey biome instead of tiny grey trees (model by Phiwari123)
+- Redwood Trees now spawn in Mesa biome (model by Wes42033)
+- BakedClay mod no longer required for Mesa biome but used if found
+- Paper Wall added
+
+#### 0.0.9o
+
+- Added Obsidian Brick craft for building
+- Changed Illumishroom cave levels
+- Changed *is_ground_content* to false for ethereal dirt so mapgen doesn't carve it up with caves
+
+#### 0.0.9n
+
+- New textures for farming mushrooms and spores
+- Illumi-shrooms spawn in caves to brighten things up a little
+- Crafting a wooden sign now gives 4 instead of 1
+
+#### 0.0.9m
+
+- Changed Bamboo biome slightly, Bamboo Sprout has new image
+- Abm timings changed and a few bugs fixed
+- Crystal Gilly Staff has to be used (left-click) to replenish air while underwater
+- Crystal Shovel now works with protection mods
+- Tidied code and changed ladder recipe's to double output
+
+#### 0.0.9L
+
+- Scorched Tree's are now different sizes
+- Crystal Shovel with soft touch can now be used to dig up sand and gravel
+- Bamboo and Papyrus drop entire stalk when bottom node dug
+- Crystal Spikes require steel pick or better to dig and fall when dirt below is removed
+- Few changes to mapgen and water functions
+
+#### 0.0.9k
+
+- Fixed bug in charcoal lumps (no more placing as unknown nodes)
+- Added Crystal Shovel with soft touch, can be used to dig up dirt with grass intact
+- Fixed bug in Crystal Shovel, now works with dirt_with_snow and has sounds
+- Tweaked Fiery Biomes slightly, smaller craters on outside, large in hotter areas
+
+#### 0.0.9i
+
+- Cleaned up mapgen_v7.lua file, maps now generate a little faster
+- Removed cactus.mts, no longer required
+- Removed mushroomtwo.mts, no longer required
+- Removed bamboo.mts, no longer required
+- Removed deadtree.mts, no longer required
+- Few new textures added
+- Papyrus also spawns on jungle dirt near water
+- Replaced dead tree's with scorched tree's
+- Each scorched tree trunk crafts into 2x charcoal Lumps (fixed)
+- Torches can also be crafted from Charcoal
+
+#### 0.0.9h
+
+- Added Strawberry farming, Strawberry Seeds and new Textures
+- Tidied up mapgen_v7.lua for better spawning of plants and trees
+- Player can no longer walk through Bamboo Stalks
+
+#### 0.0.9g
+
+- Changed Ethereal's growing routine for Saplings, it now uses 1 single abm to grow all tree's
+
+#### 0.0.9f
+
+- Added Fishing to Ethereal, Fishing Rod, Worms, Fish and Cooked Fish (Left-click the water with a Baited Rod in the hope of landing your prize)
+
+#### 0.0.9e
+
+- Changed textures for Bowl, Mushroom Soup, Crystal Spike, Banana Loaf, Strawberry & Bush
+- Added Hearty Stew Recipes
+- If BakedClay mod is installed, Mesa Biome will be added to the mix
+
+#### 0.0.9d
+
+- Added Bamboo Grove and Bamboo Sprouts )
+- Craft Bamboo into Paper and Bamboo Flooring
+- Cactus is now edible when crafted beside empty bucket
+
+#### 0.0.9c
+
+- Code re-worked so mod now uses sections for each function (easier to read and edit)
+- New textures for Strawberry Bush and Crystal Spikes
+
+#### 0.0.9b
+
+- Pine Tree Leaves have new texture and sometimes give Pine Nuts
+- Jungle Tree's now use default Jungle Wood as texture
+
+#### 0.0.9
+
+- Prairie, Grove, Jungle and Snowy biomes have their own dirt
+- Saplings will only grow in the biomes they were taken from
+- Mapgen tweaks and code changes for new dirt added
+
+### 0.0.8 Changes
+#### 0.0.8m
+
+- Added Banana Trunk and Wood
+- Added Boston Ferns to Grove biome
+- Added edible Fern Tubers
+- Mushroom Biome now has different sized mushrooms
+- Changed Pine Needles texture
+
+#### 0.0.8k
+
+- Added Desert Sand biome
+- Added Alpine biome with Pine Trees and Snow
+- Added Grove biome with Banana Tree's (saplings only grow in that temperate area)
+- Added Bananas, Banana Dough and Banana Bread
+- Changed biome generation to be more like real-world environs (e.g. shrooms like hot & humid so that's where they spawn)
+- Tidied up code and removed redundant lines
+
+#### 0.0.8e
+
+- New Plains biome added between Fiery and Green areas to hopefully stop forest fires, these have dry dirt and dead trees
+- Placing water near Dry Dirt turns it into normal dirt, cooking normal dirt changes it into Dry Dirt
+
+Note: if your Ethereal world does have a few forest fires appearing you can always add this line to your minetest.conf file:
+
+disable_fire = true
+
+#### 0.0.8
+
+- Healing Tree (grows on high snowy peaks, leaves are edible and golden apples heal all hearts)
+- Added some new images for Cooked Mushroom Soup, Mushroom Spores and Palm Trees
+- 2D leaves or 3D leaves option, both wave in wind if enabled
+- All new saplings can grow on their native dirt, and palm tree's on sand
+- Crystal Spike or Crystal Dirt freezes nearby water, Heat can also melt ice
+- Wild Mushrooms now give Spores, plant these to grow edible mushrooms
+- Cobble in water turns mossy
+- Palm Leaves can be cooked into Palm Wax and made into Candles
+
+### 0.0.7c
+
+- Gravel can be found under lake biomes (or craft 5 cobble in X pattern)
+- Papyrus is found and grows on dirt near water (also craft 2x3 string for paper)
+- Mushroom Heads have a chance of giving Mushroom Sapling (craft 1 head = 4x Mushrooms ready for Planting)
+- Trees and Mushrooms have a chance of giving Saplings
+- Frost Trunk and Mushroom Trunk are rotatable (craft 1 Mushroom Trunk = 4x White Dye)
+- Desert areas have Dry Shrubs added
+- Crystal Spikes added to Crystal Biome (watch out they hurt)
+- Crystal Ingots added to make Sword and Pick
+- New Pine Tree model added to snowy biome which adds Pine leaves and drops Pine Saplings
+- Fixed GrassyTwo biome so that BigTree now spawns and grows from sapling
+- Added Crystal Gilly Staff to allow breathing underwater (so long as it's in hand)
+- Added Palm Trees, Trunk, Wood, Sapling, Coconuts, Coconut Slice (to eat)
+- Thanks to VanessaE's for the Palm textures

+ 308 - 0
mods/ethereal/biomes.lua

@@ -0,0 +1,308 @@
+
+-- clear default mapgen biomes, decorations but keep ores
+minetest.clear_registered_biomes()
+minetest.clear_registered_decorations()
+--minetest.clear_registered_ores()
+
+-- helper strings
+local tmp, tmp2
+
+-- helper function
+local add_biome = function(a, l, m, n, o, p, b, c, d, e, f, g)
+
+	-- if not 1 then biome disabled, don't add
+	if p ~= 1 then return end
+
+	minetest.register_biome({
+		name = a,
+		node_dust = b,
+		node_top = c,
+		depth_top = d,
+		node_filler = e,
+		depth_filler = f,
+		node_stone = g,
+--		node_water_top = h,
+--		depth_water_top = i,
+--		node_water = j,
+--		node_river_water = k,
+		y_min = l,
+		y_max = m,
+		heat_point = n,
+		humidity_point = o
+	})
+end
+
+-- add_biome(name, y_min, y_max, heat, humidity, biome enabled,
+--       dust node, top node, depth, filler node, depth, stone node)
+
+
+-- always registered biomes
+add_biome("mountain", 140, 31000, 50, 50, 1,
+	nil, "default:snow", 1, "default:snowblock", 2)
+
+add_biome("clearing", 3, 71, 45, 65, 1,
+	nil, "default:dirt_with_grass", 1, "default:dirt", 3)
+
+add_biome("underground", -31000, -192, 50, 50, 1,
+	nil, nil, nil, nil, nil)
+
+
+-- biomes with disable setting
+tmp = "default:desert_stone"
+
+add_biome("desert", 3, 23, 35, 20, ethereal.desert,
+	nil, "default:desert_sand", 1, "default:desert_sand", 3, tmp)
+
+add_biome("desert_ocean", -192, 3, 35, 20, ethereal.desert,
+	nil, "default:sand", 1, "default:sand", 2, tmp)
+
+
+add_biome("bamboo", 25, 70, 45, 75, ethereal.bamboo,
+	nil, "ethereal:bamboo_dirt", 1, "default:dirt", 3)
+
+add_biome("sakura", 3, 25, 45, 75, ethereal.sakura,
+	nil, "ethereal:bamboo_dirt", 1, "default:dirt", 3)
+
+add_biome("sakura_ocean", -192, 2, 45, 75, ethereal.sakura,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+add_biome("mesa", 1, 71, 25, 28, ethereal.mesa,
+	nil, "default:dirt_with_dry_grass", 1, "bakedclay:orange", 15)
+
+add_biome("mesa_ocean", -192, 1, 25, 28, ethereal.mesa,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+tmp = "default:dirt_with_coniferous_litter"
+if not minetest.registered_nodes[tmp] then
+	tmp = "ethereal:cold_dirt"
+end
+
+add_biome("snowy", 4, 40, 10, 40, ethereal.snowy,
+	nil, tmp, 1, "default:dirt", 2)
+
+add_biome("alpine", 40, 140, 10, 40, ethereal.alpine,
+	nil, "default:dirt_with_snow", 1, "default:dirt", 2)
+
+
+add_biome("frost", 1, 71, 10, 40, ethereal.frost,
+	nil, "ethereal:crystal_dirt", 1, "default:dirt", 3)
+
+add_biome("frost_ocean", -192, 1, 10, 40, ethereal.frost,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+add_biome("grassy", 3, 91, 13, 40, ethereal.grassy,
+	nil, "default:dirt_with_grass", 1, "default:dirt", 3)
+
+add_biome("grassy_ocean", -31000, 3, 13, 40, ethereal.grassy,
+	nil, "default:sand", 2, "default:gravel", 1)
+
+
+add_biome("caves", 4, 41, 15, 25, ethereal.caves,
+	nil, "default:desert_stone", 3, "air", 8)
+
+
+tmp = "default:silver_sand"
+if not minetest.registered_nodes[tmp] then
+	tmp = "default:sand"
+end
+
+add_biome("grayness", 2, 41, 15, 30, ethereal.grayness,
+	nil, "ethereal:gray_dirt", 1, "default:dirt", 3)
+
+add_biome("grayness_ocean", -192, 1, 15, 30, ethereal.grayness,
+	nil, tmp, 2, "default:sand", 2)
+
+
+add_biome("grassytwo", 1, 91, 15, 40, ethereal.grassytwo,
+	nil, "default:dirt_with_grass", 1, "default:dirt", 3)
+
+add_biome("grassytwo_ocean", -192, 1, 15, 40, ethereal.grassytwo,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+add_biome("prairie", 3, 26, 20, 40, ethereal.prairie,
+	nil, "ethereal:prairie_dirt", 1, "default:dirt", 3)
+
+add_biome("prairie_ocean", -192, 1, 20, 40, ethereal.prairie,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+add_biome("jumble", 1, 71, 25, 50, ethereal.jumble,
+	nil, "default:dirt_with_grass", 1, "default:dirt", 3)
+
+add_biome("jumble_ocean", -192, 1, 25, 50, ethereal.jumble,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+tmp = "default:dirt_with_rainforest_litter"
+if not minetest.registered_nodes[tmp] then
+	tmp = "ethereal:jungle_dirt"
+end
+
+add_biome("junglee", 1, 71, 30, 60, ethereal.junglee,
+	nil, tmp, 1, "default:dirt", 3)
+
+add_biome("junglee_ocean", -192, 1, 30, 60, ethereal.junglee,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+add_biome("grove", 3, 23, 45, 35, ethereal.grove,
+	nil, "ethereal:grove_dirt", 1, "default:dirt", 3)
+
+add_biome("grove_ocean", -192, 2, 45, 35, ethereal.grove,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+add_biome("mushroom", 3, 50, 45, 55, ethereal.mushroom,
+	nil, "ethereal:mushroom_dirt", 1, "default:dirt", 3)
+
+add_biome("mushroom_ocean", -192, 2, 45, 55, ethereal.mushroom,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+add_biome("sandstone", 3, 23, 50, 20, ethereal.sandstone,
+	nil, "default:sandstone", 1, "default:sandstone", 1, "default:sandstone")
+
+add_biome("sandstone_ocean", -192, 2, 50, 20, ethereal.sandstone,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+add_biome("quicksand", 1, 1, 50, 38, ethereal.quicksand,
+	nil, "ethereal:quicksand2", 3, "default:gravel", 1)
+
+
+add_biome("plains", 3, 25, 65, 25, ethereal.plains,
+	nil, "ethereal:dry_dirt", 1, "default:dirt", 3)
+
+add_biome("plains_ocean", -192, 2, 55, 25, ethereal.plains,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+tmp = "default:dry_dirt_with_dry_grass"
+tmp2 = "default:dry_dirt"
+if not minetest.registered_nodes[tmp] then
+	tmp = "default:dirt_with_dry_grass"
+	tmp2 = "default:dirt"
+end
+
+add_biome("savanna", 3, 50, 55, 25, ethereal.savanna,
+	nil, tmp, 1, tmp2, 3)
+
+add_biome("savanna_ocean", -192, 1, 55, 25, ethereal.savanna,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+add_biome("fiery", 5, 20, 75, 10, ethereal.fiery,
+	nil, "ethereal:fiery_dirt", 1, "default:dirt", 3)
+
+add_biome("fiery_ocean", -192, 4, 75, 10, ethereal.fiery,
+	nil, "default:sand", 1, "default:sand", 2)
+
+
+add_biome("sandclay", 1, 11, 65, 2, ethereal.sandclay,
+	nil, "default:sand", 3, "default:clay", 2)
+
+
+add_biome("swamp", 1, 7, 80, 90, ethereal.swamp,
+	nil, "default:dirt_with_grass", 1, "default:dirt", 3)
+
+add_biome("swamp_ocean", -192, 1, 80, 90, ethereal.swamp,
+	nil, "default:sand", 2, "default:clay", 2)
+
+
+if ethereal.glacier == 1 then
+
+	minetest.register_biome({
+		name = "glacier",
+		node_dust = "default:snowblock",
+		node_top = "default:snowblock",
+		depth_top = 1,
+		node_filler = "default:snowblock",
+		depth_filler = 3,
+		node_stone = "default:ice",
+		node_water_top = "default:ice",
+		depth_water_top = 10,
+		node_river_water = "default:ice",
+		node_riverbed = "default:gravel",
+		depth_riverbed = 2,
+		y_min = -8,
+		y_max = 31000,
+		heat_point = 0,
+		humidity_point = 50,
+	})
+
+	minetest.register_biome({
+		name = "glacier_ocean",
+		node_dust = "default:snowblock",
+		node_top = "default:sand",
+		depth_top = 1,
+		node_filler = "default:sand",
+		depth_filler = 3,
+		y_min = -112,
+		y_max = -9,
+		heat_point = 0,
+		humidity_point = 50,
+	})
+end
+
+if ethereal.tundra and minetest.registered_nodes["default:permafrost"] then
+
+	minetest.register_biome({
+		name = "tundra_highland",
+		node_dust = "default:snow",
+		node_riverbed = "default:gravel",
+		depth_riverbed = 2,
+		y_max = 180,
+		y_min = 47,
+		heat_point = 0,
+		humidity_point = 40,
+	})
+
+	minetest.register_biome({
+		name = "tundra",
+		node_top = "default:permafrost_with_stones",
+		depth_top = 1,
+		node_filler = "default:permafrost",
+		depth_filler = 1,
+		node_riverbed = "default:gravel",
+		depth_riverbed = 2,
+		vertical_blend = 4,
+		y_max = 46,
+		y_min = 2,
+		heat_point = 0,
+		humidity_point = 40,
+	})
+
+	minetest.register_biome({
+		name = "tundra_beach",
+		node_top = "default:gravel",
+		depth_top = 1,
+		node_filler = "default:gravel",
+		depth_filler = 2,
+		node_riverbed = "default:gravel",
+		depth_riverbed = 2,
+		vertical_blend = 1,
+		y_max = 1,
+		y_min = -3,
+		heat_point = 0,
+		humidity_point = 40,
+	})
+
+	minetest.register_biome({
+		name = "tundra_ocean",
+		node_top = "default:sand",
+		depth_top = 1,
+		node_filler = "default:sand",
+		depth_filler = 3,
+		node_riverbed = "default:gravel",
+		depth_riverbed = 2,
+		vertical_blend = 1,
+		y_max = -4,
+		y_min = -112,
+		heat_point = 0,
+		humidity_point = 40,
+	})
+end

+ 46 - 0
mods/ethereal/compatibility.lua

@@ -0,0 +1,46 @@
+
+-- add compatibility for ethereal nodes already in default game or name changed
+minetest.register_alias("ethereal:acacia_trunk", "default:acacia_tree")
+minetest.register_alias("ethereal:acacia_wood", "default:acacia_wood")
+
+minetest.register_alias("ethereal:fence_acacia", "default:fence_acacia_wood")
+minetest.register_alias("ethereal:fence_junglewood", "default:fence_junglewood")
+minetest.register_alias("ethereal:fence_pine", "default:fence_pine_wood")
+
+minetest.register_alias("ethereal:acacia_leaves", "default:acacia_leaves")
+minetest.register_alias("ethereal:pineleaves", "default:pine_needles")
+
+minetest.register_alias("ethereal:mushroom_craftingitem", "flowers:mushroom_brown")
+minetest.register_alias("ethereal:mushroom_plant", "flowers:mushroom_brown")
+minetest.register_alias("ethereal:mushroom_soup_cooked", "ethereal:mushroom_soup")
+minetest.register_alias("ethereal:mushroom_1", "flowers:mushroom_brown")
+minetest.register_alias("ethereal:mushroom_2", "flowers:mushroom_brown")
+minetest.register_alias("ethereal:mushroom_3", "flowers:mushroom_brown")
+minetest.register_alias("ethereal:mushroom_4", "flowers:mushroom_brown")
+
+minetest.register_alias("ethereal:strawberry_bush", "ethereal:strawberry_7")
+minetest.register_alias("ethereal:seed_strawberry", "ethereal:strawberry")
+
+for i = 1, 5 do
+	minetest.register_alias("ethereal:wild_onion_"..i, "ethereal:onion_"..i)
+end
+
+minetest.register_alias("ethereal:onion_7", "ethereal:onion_4")
+minetest.register_alias("ethereal:onion_8", "ethereal:onion_5")
+minetest.register_alias("ethereal:wild_onion_7", "ethereal:onion_4")
+minetest.register_alias("ethereal:wild_onion_8", "ethereal:onion_5")
+minetest.register_alias("ethereal:wild_onion_craftingitem", "ethereal:wild_onion_plant")
+
+minetest.register_alias("ethereal:hearty_stew_cooked", "ethereal:hearty_stew")
+
+minetest.register_alias("ethereal:obsidian_brick", "default:obsidianbrick")
+
+minetest.register_alias("ethereal:crystal_topped_dirt", "ethereal:crystal_dirt")
+minetest.register_alias("ethereal:fiery_dirt_top", "ethereal:fiery_dirt")
+minetest.register_alias("ethereal:gray_dirt_top", "ethereal:gray_dirt")
+minetest.register_alias("ethereal:green_dirt_top", "default;dirt_with_grass")
+
+minetest.register_alias("ethereal:tree_sapling", "default:sapling")
+minetest.register_alias("ethereal:jungle_tree_sapling", "default:junglesapling")
+minetest.register_alias("ethereal:acacia_sapling", "default:acacia_sapling")
+minetest.register_alias("ethereal:pine_tree_sapling", "default:pine_sapling")

+ 311 - 0
mods/ethereal/crystal.lua

@@ -0,0 +1,311 @@
+
+local S = ethereal.intllib
+
+-- Crystal Spike (Hurts if you touch it - thanks to ZonerDarkRevention for his DokuCraft DeviantArt crystal texture)
+minetest.register_node("ethereal:crystal_spike", {
+	description = S("Crystal Spike"),
+	drawtype = "plantlike",
+	tiles = { "crystal_spike.png" },
+	inventory_image = "crystal_spike.png",
+	wield_image = "crystal_spike.png",
+	paramtype = "light",
+	light_source = 7,
+	sunlight_propagates = true,
+	walkable = true,
+	damage_per_second = 1,
+	groups = {cracky = 1, falling_node = 1, puts_out_fire = 1, cools_lava = 1},
+	sounds = default.node_sound_glass_defaults(),
+	selection_box = {
+		type = "fixed",
+		fixed = {-5 / 16, -0.5, -5 / 16, 5 / 16, 0, 5 / 16},
+	},
+	node_box = {
+		type = "fixed",
+		fixed = {-5 / 16, -0.5, -5 / 16, 5 / 16, 0, 5 / 16},
+	},
+})
+
+-- Crystal Ingot
+minetest.register_craftitem("ethereal:crystal_ingot", {
+	description = S("Crystal Ingot"),
+	inventory_image = "crystal_ingot.png",
+	wield_image = "crystal_ingot.png",
+})
+
+if minetest.get_modpath("builtin_item") then
+
+	minetest.override_item("ethereal:crystal_spike", {
+
+		dropped_step = function(self, pos, dtime)
+
+			self.ctimer = (self.ctimer or 0) + dtime
+			if self.ctimer < 5.0 then return end
+			self.ctimer = 0
+
+			if self.node_inside
+			and self.node_inside.name ~= "default:water_source" then
+				return
+			end
+
+			local objs = core.get_objects_inside_radius(pos, 0.8)
+
+			if not objs or #objs ~= 2 then return end
+
+			local crystal, mese, ent = nil, nil, nil
+
+			for k, obj in pairs(objs) do
+
+				ent = obj:get_luaentity()
+
+				if ent and ent.name == "__builtin:item" then
+
+					if ent.itemstring == "default:mese_crystal 2"
+					and not mese then
+
+						mese = obj
+
+					elseif ent.itemstring == "ethereal:crystal_spike 2"
+					and not crystal then
+
+						crystal = obj
+					end
+				end
+			end
+
+			if mese and crystal then
+
+				mese:remove()
+				crystal:remove()
+
+				core.add_item(pos, "ethereal:crystal_ingot")
+
+				return false
+			end
+		end
+	})
+end
+
+minetest.register_craft({
+	type = "shapeless",
+	output = "ethereal:crystal_ingot",
+	recipe = {
+		"default:mese_crystal", "ethereal:crystal_spike",
+		"ethereal:crystal_spike", "default:mese_crystal", "bucket:bucket_water"
+	},
+	replacements = { {"bucket:bucket_water", "bucket:bucket_empty"} }
+})
+
+-- Crystal Block
+minetest.register_node("ethereal:crystal_block", {
+	description = S("Crystal Block"),
+	tiles = {"crystal_block.png"},
+	light_source = 9,
+	is_ground_content = false,
+	groups = {cracky = 1, level = 2, puts_out_fire = 1, cools_lava = 1},
+	sounds = default.node_sound_glass_defaults(),
+})
+
+minetest.register_craft({
+	output = "ethereal:crystal_block",
+	recipe = {
+		{"ethereal:crystal_ingot", "ethereal:crystal_ingot", "ethereal:crystal_ingot"},
+		{"ethereal:crystal_ingot", "ethereal:crystal_ingot", "ethereal:crystal_ingot"},
+		{"ethereal:crystal_ingot", "ethereal:crystal_ingot", "ethereal:crystal_ingot"},
+	}
+})
+
+minetest.register_craft({
+	output = "ethereal:crystal_ingot 9",
+	recipe = {
+		{"ethereal:crystal_block"},
+	}
+})
+
+-- Crystal Sword (Powerful wee beastie)
+minetest.register_tool("ethereal:sword_crystal", {
+	description = S("Crystal Sword"),
+	inventory_image = "crystal_sword.png",
+	wield_image = "crystal_sword.png",
+	tool_capabilities = {
+		full_punch_interval = 0.6,
+		max_drop_level = 1,
+		groupcaps = {
+			snappy = {
+				times = {[1] = 1.70, [2] = 0.70, [3] = 0.25},
+				uses = 50,
+				maxlevel = 3
+			},
+		},
+		damage_groups = {fleshy = 10},
+	},
+	groups = {sword = 1},
+	sound = {breaks = "default_tool_breaks"},
+})
+
+minetest.register_craft({
+	output = "ethereal:sword_crystal",
+	recipe = {
+		{"ethereal:crystal_ingot"},
+		{"ethereal:crystal_ingot"},
+		{"default:steel_ingot"},
+	}
+})
+
+-- Crystal Axe
+minetest.register_tool("ethereal:axe_crystal", {
+	description = S("Crystal Axe"),
+	inventory_image = "crystal_axe.png",
+	wield_image = "crystal_axe.png",
+	tool_capabilities = {
+		full_punch_interval = 0.8,
+		max_drop_level = 1,
+		groupcaps = {
+			choppy = {
+				times = {[1] = 2.00, [2] = 0.80, [3] = 0.40},
+				uses = 40,
+				maxlevel = 3
+			},
+		},
+		damage_groups = {fleshy = 7},
+	},
+	groups = {axe = 1},
+	sound = {breaks = "default_tool_breaks"},
+})
+
+minetest.register_craft({
+	output = "ethereal:axe_crystal",
+	recipe = {
+		{"ethereal:crystal_ingot", "ethereal:crystal_ingot"},
+		{"ethereal:crystal_ingot", "default:steel_ingot"},
+		{"", "default:steel_ingot"},
+	}
+})
+
+minetest.register_craft({
+	output = "ethereal:axe_crystal",
+	recipe = {
+		{"ethereal:crystal_ingot", "ethereal:crystal_ingot"},
+		{"default:steel_ingot", "ethereal:crystal_ingot"},
+		{"default:steel_ingot", ""},
+	}
+})
+
+-- Crystal Pick (This will last a while)
+minetest.register_tool("ethereal:pick_crystal", {
+	description = S("Crystal Pickaxe"),
+	inventory_image = "crystal_pick.png",
+	wield_image = "crystal_pick.png",
+	tool_capabilities = {
+		full_punch_interval = 0.7,
+		max_drop_level = 3,
+		groupcaps={
+			cracky = {
+				times = {[1] = 1.8, [2] = 0.8, [3] = 0.40},
+				uses = 40,
+				maxlevel = 3
+			},
+		},
+		damage_groups = {fleshy = 6},
+	},
+	groups = {pickaxe = 1},
+	sound = {breaks = "default_tool_breaks"},
+})
+
+minetest.register_craft({
+	output = "ethereal:pick_crystal",
+	recipe = {
+		{"ethereal:crystal_ingot", "ethereal:crystal_ingot", "ethereal:crystal_ingot"},
+		{"", "default:steel_ingot", ""},
+		{"", "default:steel_ingot", ""},
+	}
+})
+
+local old_handle_node_drops = minetest.handle_node_drops
+
+function minetest.handle_node_drops(pos, drops, digger)
+
+	-- are we holding Crystal Shovel?
+	if digger:get_wielded_item():get_name() ~= "ethereal:shovel_crystal" then
+		return old_handle_node_drops(pos, drops, digger)
+	end
+
+	local nn = minetest.get_node(pos).name
+
+	if minetest.get_item_group(nn, "crumbly") == 0 then
+		return old_handle_node_drops(pos, drops, digger)
+	end
+
+	return old_handle_node_drops(pos, {ItemStack(nn)}, digger)
+end
+
+
+minetest.register_tool("ethereal:shovel_crystal", {
+	description = "Crystal Shovel",
+	inventory_image = "crystal_shovel.png",
+	wield_image = "crystal_shovel.png^[transformR90",
+	tool_capabilities = {
+		full_punch_interval = 1.0,
+		max_drop_level = 1,
+		groupcaps = {
+			crumbly = {
+				times = {[1] = 1.10, [2] = 0.50, [3] = 0.30},
+				uses = 30,
+				maxlevel = 3
+			},
+		},
+		damage_groups = {fleshy = 4},
+	},
+	groups = {shovel = 1},
+	sound = {breaks = "default_tool_breaks"},
+})
+
+minetest.register_craft({
+	output = "ethereal:shovel_crystal",
+	recipe = {
+		{"ethereal:crystal_ingot"},
+		{"default:steel_ingot"},
+		{"default:steel_ingot"},
+	}
+})
+
+-- Crystal Gilly Staff (replenishes air supply when used)
+minetest.register_tool("ethereal:crystal_gilly_staff", {
+	description = S("Crystal Gilly Staff"),
+	inventory_image = "crystal_gilly_staff.png",
+	wield_image = "crystal_gilly_staff.png",
+
+	on_use = function(itemstack, user, pointed_thing)
+		if user:get_breath() < 10 then
+			user:set_breath(10)
+		end
+	end,
+})
+
+minetest.register_craft({
+	type = "shapeless",
+	output = "ethereal:crystal_gilly_staff",
+	recipe = {
+		"ethereal:green_moss", "ethereal:gray_moss", "ethereal:fiery_moss",
+		"ethereal:crystal_moss", "ethereal:crystal_ingot", "ethereal:mushroom_moss",
+		"ethereal:crystal_ingot"
+	},
+})
+
+-- Add [toolranks] mod support if found
+if minetest.get_modpath("toolranks") then
+
+	-- Helper function
+	local function add_tool(name, desc, afteruse)
+
+		minetest.override_item(name, {
+			original_description = desc,
+			description = toolranks.create_description(desc, 0, 1),
+			after_use = afteruse and toolranks.new_afteruse
+		})
+	end
+
+	add_tool("ethereal:pick_crystal", "Crystal Pickaxe", true)
+	add_tool("ethereal:axe_crystal", "Crystal Axe", true)
+	add_tool("ethereal:shovel_crystal", "Crystal Shovel", true)
+	add_tool("ethereal:sword_crystal", "Crystal Sword", true)
+end

+ 731 - 0
mods/ethereal/decor.lua

@@ -0,0 +1,731 @@
+
+if minetest.registered_nodes["farming:cotton_wild"] then
+minetest.register_decoration({
+	name = "farming:cotton_wild",
+	deco_type = "simple",
+	place_on = {"default:dry_dirt_with_dry_grass"},
+	sidelen = 16,
+	noise_params = {
+		offset = -0.1,
+		scale = 0.1,
+		spread = {x = 50, y = 50, z = 50},
+		seed = 4242,
+		octaves = 3,
+		persist = 0.7
+	},
+	biomes = {"savanna"},
+	y_max = 31000,
+	y_min = 1,
+	decoration = "farming:cotton_wild",
+})
+end
+
+-- water pools in swamp areas if 5.0 detected
+if minetest.registered_nodes["default:permafrost"] then
+minetest.register_decoration({
+	deco_type = "simple",
+	place_on = {"default:dirt_with_grass"},
+	place_offset_y = -1,
+	sidelen = 16,
+	fill_ratio = 0.01,
+	biomes = {"swamp"},
+	y_max = 2,
+	y_min = 1,
+	flags = "force_placement",
+	decoration = "default:water_source",
+	spawn_by = "default:dirt_with_grass",
+	num_spawn_by = 8,
+})
+minetest.register_decoration({
+	deco_type = "simple",
+	place_on = {"default:dirt_with_grass"},
+	place_offset_y = -1,
+	sidelen = 16,
+	fill_ratio = 0.1,
+	biomes = {"swamp"},
+	y_max = 2,
+	y_min = 1,
+	flags = "force_placement",
+	decoration = "default:water_source",
+	spawn_by = {"default:dirt_with_grass", "default:water_source"},
+	num_spawn_by = 8,
+})
+end
+
+if minetest.registered_nodes["default:dry_dirt_with_dry_grass"] then
+	minetest.register_decoration({
+		deco_type = "simple",
+		place_on = {"default:dry_dirt_with_dry_grass"},
+		sidelen = 4,
+		noise_params = {
+			offset = -1.5,
+			scale = -1.5,
+			spread = {x = 200, y = 200, z = 200},
+			seed = 329,
+			octaves = 4,
+			persist = 1.0
+		},
+		biomes = {"savanna"},
+		y_max = 31000,
+		y_min = 1,
+		decoration = "default:dry_dirt",
+		place_offset_y = -1,
+		flags = "force_placement",
+	})
+end
+
+
+-- helper string
+local tmp
+
+-- helper function
+local add_node = function(a, b, c, d, e, f, g, h, i, j)
+
+	if j ~= 1 then return end
+
+	minetest.register_decoration({
+		deco_type = "simple",
+		place_on = a,
+		sidelen = 80,
+		fill_ratio = b,
+		biomes = c,
+		y_min = d,
+		y_max = e,
+		decoration = f,
+		height_max = g,
+		spawn_by = h,
+		num_spawn_by = i,
+	})
+end
+
+
+--firethorn shrub
+add_node({"default:snowblock"}, 0.001, {"glacier"}, 1, 30,
+	{"ethereal:firethorn"}, nil, nil, nil, ethereal.glacier)
+
+-- scorched tree
+add_node({"ethereal:dry_dirt"}, 0.006, {"plains"}, 1, 100,
+	{"ethereal:scorched_tree"}, 6, nil, nil, ethereal.plains)
+
+-- dry shrub
+add_node({"ethereal:dry_dirt"}, 0.015, {"plains"}, 1, 100,
+	{"default:dry_shrub"}, nil, nil, nil, ethereal.plains)
+
+add_node({"default:sand"}, 0.015, {"grassy_ocean"}, 1, 100,
+	{"default:dry_shrub"}, nil, nil, nil, ethereal.grassy)
+
+add_node({"default:desert_sand"}, 0.015, {"desert"}, 1, 100,
+	{"default:dry_shrub"}, nil, nil, nil, ethereal.desert)
+
+add_node({"default:sandstone"}, 0.015, {"sandstone"}, 1, 100,
+	{"default:dry_shrub"}, nil, nil, nil, ethereal.sandstone)
+
+add_node({"bakedclay:red", "bakedclay:orange"}, 0.015, {"mesa"}, 1, 100,
+	{"default:dry_shrub"}, nil, nil, nil, ethereal.mesa)
+
+-- dry grass
+add_node({"default:dry_dirt_with_dry_grass",
+	"default:dirt_with_dry_grass"}, 0.25, {"savanna"}, 1, 100,
+	{"default:dry_grass_2", "default:dry_grass_3", "default:dry_grass_4",
+	"default:dry_grass_5"}, nil, nil, nil, ethereal.savanna)
+
+add_node({"default:dirt_with_dry_grass"}, 0.10, {"mesa"}, 1, 100,
+	{"default:dry_grass_2", "default:dry_grass_3", "default:dry_grass_4",
+	"default:dry_grass_5"}, nil, nil, nil, ethereal.mesa)
+
+add_node({"default:desert_stone"}, 0.005, {"caves"}, 5, 40,
+	{"default:dry_grass_2", "default:dry_grass_3", "default:dry_shrub"},
+	nil, nil, nil, ethereal.caves)
+
+-- flowers & strawberry
+add_node({"default:dirt_with_grass"}, 0.025, {"grassy"}, 1, 100,
+	{"flowers:dandelion_white", "flowers:dandelion_yellow",
+	"flowers:geranium", "flowers:rose", "flowers:tulip",
+     "flowers:viola", "ethereal:strawberry_7"}, nil, nil, nil,
+	ethereal.grassy)
+
+add_node({"default:dirt_with_grass"}, 0.025, {"grassytwo"}, 1, 100,
+	{"flowers:dandelion_white", "flowers:dandelion_yellow",
+	"flowers:geranium", "flowers:rose", "flowers:tulip",
+	"flowers:viola", "ethereal:strawberry_7"}, nil, nil, nil,
+	ethereal.grassytwo)
+
+-- prairie flowers & strawberry
+add_node({"ethereal:prairie_dirt"}, 0.035, {"prairie"}, 1, 100,
+	{"flowers:dandelion_white", "flowers:dandelion_yellow",
+	"flowers:geranium", "flowers:rose", "flowers:tulip",
+	"flowers:viola", "ethereal:strawberry_7",
+	"flowers:chrysanthemum_green", "flowers:tulip_black"}, nil, nil, nil,
+	ethereal.prairie)
+
+-- crystal spike & crystal grass
+add_node({"ethereal:crystal_dirt"}, 0.02, {"frost"}, 1, 100,
+	{"ethereal:crystal_spike", "ethereal:crystalgrass"}, nil, nil, nil,
+	ethereal.frost)
+
+-- red shrub
+add_node({"ethereal:fiery_dirt"}, 0.10, {"fiery"}, 1, 100,
+	{"ethereal:dry_shrub"}, nil, nil, nil, ethereal.fiery)
+
+-- snowy grass
+add_node({"ethereal:gray_dirt"}, 0.05, {"grayness"}, 1, 100,
+	{"ethereal:snowygrass"}, nil, nil, nil, ethereal.grayness)
+
+add_node({"ethereal:cold_dirt", "default:dirt_with_coniferous_litter"}, 0.05,
+	{"snowy"}, 1, 100, {"ethereal:snowygrass"}, nil, nil, nil, ethereal.snowy)
+
+-- cactus
+add_node({"default:sandstone"}, 0.0025, {"sandstone"}, 1, 100,
+	{"default:cactus"}, 3, nil, nil, ethereal.sandstone)
+
+add_node({"default:desert_sand"}, 0.005, {"desert"}, 1, 100,
+	{"default:cactus"}, 4, nil, nil, ethereal.desert)
+
+-- wild red mushroom
+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", "default:dirt_with_rainforest_litter"}, ethereal.junglee},
+	{"grassy", {"default:dirt_with_grass"}, ethereal.grassy},
+	{"grassytwo", {"default:dirt_with_grass"}, ethereal.grassytwo},
+	{"prairie", {"ethereal:prairie_dirt"}, ethereal.prairie},
+	{"mushroom", {"ethereal:mushroom_dirt"}, ethereal.mushroom},
+	{"swamp", {"default:dirt_with_grass"}, ethereal.swamp},
+}
+
+-- wild red and brown mushrooms
+for _, row in pairs(list) do
+
+if row[3] == 1 then
+minetest.register_decoration({
+	deco_type = "simple",
+	place_on = row[2],
+	sidelen = 16,
+	noise_params = {
+		offset = 0,
+		scale = 0.009,
+		spread = {x = 200, y = 200, z = 200},
+		seed = 2,
+		octaves = 3,
+		persist = 0.66
+	},
+	biomes = {row[1]},
+	y_min = 1,
+	y_max = 120,
+	decoration = {"flowers:mushroom_brown", "flowers:mushroom_red"},
+})
+end
+
+end
+
+-- jungle grass
+add_node({"ethereal:jungle_dirt", "default:dirt_with_rainforest_litter"},
+	0.10, {"junglee"}, 1, 100, {"default:junglegrass"}, nil, nil, nil,
+	ethereal.junglee)
+
+add_node({"default:dirt_with_grass"}, 0.15, {"jumble"}, 1, 100,
+	{"default:junglegrass"}, nil, nil, nil, ethereal.jumble)
+
+add_node({"default:dirt_with_grass"}, 0.25, {"swamp"}, 1, 100,
+	{"default:junglegrass"}, nil, nil, nil, ethereal.swamp)
+
+-- grass
+add_node({"default:dirt_with_grass"}, 0.35, {"grassy"}, 1, 100,
+	{"default:grass_2", "default:grass_3", "default:grass_4",
+	"default:grass_5"}, nil, nil, nil, ethereal.grassy)
+
+add_node({"default:dirt_with_grass"}, 0.35, {"grassytwo"}, 1, 100,
+	{"default:grass_2", "default:grass_3", "default:grass_4",
+	"default:grass_5"}, nil, nil, nil, ethereal.grassytwo)
+
+add_node({"default:dirt_with_grass"}, 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", "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)
+
+add_node({"ethereal:grove_dirt"}, 0.35, {"grove"}, 1, 100,
+	{"default:grass_2", "default:grass_3", "default:grass_4",
+	"default:grass_5"}, nil, nil, nil, ethereal.grove)
+
+add_node({"ethereal:bamboo_dirt"}, 0.35, {"bamboo"}, 1, 100,
+	{"default:grass_2", "default:grass_3", "default:grass_4",
+	"default:grass_5"}, nil, nil, nil, ethereal.bamboo)
+
+add_node({"default:dirt_with_grass"}, 0.35, {"clearing", "swamp"},
+	1, 100, {"default:grass_3", "default:grass_4"}, nil, nil, nil, 1)
+
+add_node({"ethereal:bamboo_dirt"}, 0.35, {"sakura"}, 1, 100,
+	{"default:grass_2", "default:grass_3", "default:grass_4",
+	"default:grass_5"}, nil, nil, nil, ethereal.sakura)
+
+-- grass on sand
+if minetest.registered_nodes["default:marram_grass_1"] then
+
+add_node({"default:sand"}, 0.25, {"sandclay"}, 3, 4, {"default:marram_grass_1",
+	"default:marram_grass_2", "default:marram_grass_3"}, nil, nil, nil,
+	ethereal.sandclay)
+
+else
+
+add_node({"default:sand"}, 0.25, {"sandclay"}, 3, 4, {"default:grass_2",
+	"default:grass_3"}, nil, nil, nil, ethereal.sandclay)
+end
+
+-- ferns
+add_node({"ethereal:grove_dirt"}, 0.2, {"grove"}, 1, 100, {"ethereal:fern"},
+	nil, nil, nil, ethereal.grove)
+
+add_node({"default:dirt_with_grass"}, 0.1, {"swamp"}, 1, 100,
+	{"ethereal:fern"}, nil, nil, nil, ethereal.swamp)
+
+-- snow
+add_node({"ethereal:cold_dirt", "default:dirt_with_coniferous_litter"},
+	0.8, {"snowy"}, 4, 40, {"default:snow"}, nil, nil, nil, ethereal.snowy)
+
+add_node({"default:dirt_with_snow"}, 0.8, {"alpine"}, 40, 140,
+	{"default:snow"}, nil, nil, nil, ethereal.alpine)
+
+-- wild onion
+add_node({"default:dirt_with_grass", "ethereal:prairie_dirt"}, 0.25,
+	{"grassy", "grassytwo", "jumble", "prairie"}, 1, 100,
+	{"ethereal:onion_4"}, nil, nil, nil, 1)
+
+-- papyrus
+add_node({"default:dirt_with_grass"}, 0.1, {"grassy"}, 1, 1,
+	{"default:papyrus"}, 4, "default:water_source", 1, ethereal.grassy)
+
+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({"default:dirt_with_grass"}, 0.1, {"swamp"}, 1, 1,
+	{"default:papyrus"}, 4, "default:water_source", 1, ethereal.swamp)
+
+--= Farming Redo plants
+
+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", "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({"default:dirt_with_grass"}, 0.05, {"grassytwo"}, 1, 100,
+	{"farming:carrot_7", "farming:cucumber_4", "farming:potato_3",
+	"farming:tomato_7", "farming:corn_8", "farming:coffee_5",
+	"farming:raspberry_4", "farming:rhubarb_3", "farming:blueberry_4",
+	"farming:cabbage_6"}, nil, nil, nil, ethereal.grassytwo)
+
+add_node({"default:dirt_with_grass"}, 0.05, {"grassy"}, 1, 100,
+	{"farming:carrot_7", "farming:cucumber_4", "farming:potato_3",
+	"farming:tomato_7", "farming:corn_8", "farming:coffee_5",
+	"farming:raspberry_4", "farming:rhubarb_3", "farming:blueberry_4",
+	"farming:beetroot_5"}, nil, nil, nil, ethereal.grassy)
+
+add_node({"default:dirt_with_grass"}, 0.05, {"jumble"}, 1, 100,
+	{"farming:carrot_7", "farming:cucumber_4", "farming:potato_3",
+	"farming:tomato_7", "farming:corn_8", "farming:coffee_5",
+	"farming:raspberry_4", "farming:rhubarb_3", "farming:blueberry_4",
+	"farming:cabbage_6"}, nil, nil, nil, ethereal.jumble)
+
+add_node({"ethereal:prairie_dirt"}, 0.05, {"prairie"}, 1, 100,
+	{"farming:carrot_7", "farming:cucumber_4", "farming:potato_3",
+	"farming:tomato_7", "farming:corn_8", "farming:coffee_5",
+	"farming:raspberry_4", "farming:rhubarb_3", "farming:blueberry_4",
+	"farming:pea_5", "farming:beetroot_5"}, nil, nil, nil, ethereal.prairie)
+
+-- melon and pumpkin
+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({"default:dirt_with_grass"}, 0.015, {"grassy"}, 1, 1,
+	{"farming:melon_8", "farming:pumpkin_8"}, nil, "default:water_source",
+	1, ethereal.grassy)
+
+add_node({"default:dirt_with_grass"}, 0.015, {"grassytwo"}, 1, 1,
+	{"farming:melon_8", "farming:pumpkin_8"}, nil, "default:water_source",
+	1, ethereal.grassytwo)
+
+add_node({"default:dirt_with_grass"}, 0.015, {"jumble"}, 1, 1,
+	{"farming:melon_8", "farming:pumpkin_8"}, nil, "default:water_source",
+	1, ethereal.jumble)
+
+-- mint
+add_node({"default:dirt_with_grass", "default:dirt_with_coniferous_grass",
+	"ethereal:bamboo_dirt"}, 0.003, nil, 1, 75, "farming:mint_4", nil,
+	"group:water", 1, 1)
+
+-- green beans
+add_node({"default:dirt_with_grass"}, 0.035, {"grassytwo"}, 1, 100,
+	{"farming:beanbush"}, nil, nil, nil, ethereal.grassytwo)
+
+-- grape bushel
+add_node({"default:dirt_with_grass"}, 0.025, {"grassytwo"}, 1, 100,
+	{"farming:grapebush"}, nil, nil, nil, ethereal.grassytwo)
+
+add_node({"default:dirt_with_grass"}, 0.025, {"grassy"}, 1, 100,
+	{"farming:grapebush"}, nil, nil, nil, ethereal.grassy)
+
+add_node({"ethereal:prairie_dirt"}, 0.025, {"prairie"}, 1, 100,
+	{"farming:grapebush"}, nil, nil, nil, ethereal.prairie)
+
+minetest.register_decoration({
+	deco_type = "simple",
+	place_on = {"default:dirt_with_grass", "ethereal:prairie_dirt",
+			"default:dirt_with_rainforest_litter"},
+	sidelen = 16,
+	noise_params = {
+		offset = 0,
+		scale = 0.09,
+		spread = {x = 100, y = 100, z = 100},
+		seed = 760,
+		octaves = 3,
+		persist = 0.6
+	},
+	y_min = 5,
+	y_max = 35,
+	decoration = {"farming:chili_8", "farming:garlic_5", "farming:pepper_5",
+			"farming:onion_5", "farming:hemp_7"},
+	spawn_by = "group:tree",
+	num_spawn_by = 1,
+})
+
+minetest.register_decoration({
+	deco_type = "simple",
+	place_on = {"default:dirt_with_dry_grass"},
+	sidelen = 16,
+	noise_params = {
+		offset = 0,
+		scale = 0.06,
+		spread = {x = 100, y = 100, z = 100},
+		seed = 917,
+		octaves = 3,
+		persist = 0.6
+	},
+	y_min = 18,
+	y_max = 30,
+	decoration = {"farming:pineapple_8"},
+})
+end
+
+
+-- is baked clay mod active? add new flowers if so
+if minetest.get_modpath("bakedclay") then
+
+minetest.register_decoration({
+	deco_type = "simple",
+	place_on = {
+		"ethereal:prairie_grass", "default:dirt_with_grass",
+		"ethereal:grove_dirt"
+	},
+	sidelen = 16,
+	noise_params = {
+		offset = 0,
+		scale = 0.004,
+		spread = {x = 100, y = 100, z = 100},
+		seed = 7133,
+		octaves = 3,
+		persist = 0.6
+	},
+	y_min = 10,
+	y_max = 90,
+	decoration = "bakedclay:delphinium",
+})
+
+minetest.register_decoration({
+	deco_type = "simple",
+	place_on = {
+		"ethereal:prairie_grass", "default:dirt_with_grass",
+		"ethereal:grove_dirt", "ethereal:bamboo_dirt"
+	},
+	sidelen = 16,
+	noise_params = {
+		offset = 0,
+		scale = 0.004,
+		spread = {x = 100, y = 100, z = 100},
+		seed = 7134,
+		octaves = 3,
+		persist = 0.6
+	},
+	y_min = 15,
+	y_max = 90,
+	decoration = "bakedclay:thistle",
+})
+
+minetest.register_decoration({
+	deco_type = "simple",
+	place_on = {"ethereal:jungle_dirt", "default:dirt_with_rainforest_litter"},
+	sidelen = 16,
+	noise_params = {
+		offset = 0,
+		scale = 0.01,
+		spread = {x = 100, y = 100, z = 100},
+		seed = 7135,
+		octaves = 3,
+		persist = 0.6
+	},
+	y_min = 1,
+	y_max = 90,
+	decoration = "bakedclay:lazarus",
+	spawn_by = "default:jungletree",
+	num_spawn_by = 1,
+})
+
+minetest.register_decoration({
+	deco_type = "simple",
+	place_on = {"default:dirt_with_grass", "default:sand"},
+	sidelen = 16,
+	noise_params = {
+		offset = 0,
+		scale = 0.009,
+		spread = {x = 100, y = 100, z = 100},
+		seed = 7136,
+		octaves = 3,
+		persist = 0.6
+	},
+	y_min = 1,
+	y_max = 15,
+	decoration = "bakedclay:mannagrass",
+	spawn_by = "group:water",
+	num_spawn_by = 1,
+})
+end
+
+
+if ethereal.desert and minetest.get_modpath("wine") then
+minetest.register_decoration({
+	deco_type = "simple",
+	place_on = {"default:desert_sand"},
+	sidelen = 16,
+	fill_ratio = 0.001,
+	biomes = {"desert"},
+	decoration = {"wine:blue_agave"},
+})
+end
+
+
+if ethereal.snowy and minetest.registered_nodes["default:fern_1"] then
+local function register_fern_decoration(seed, length)
+	minetest.register_decoration({
+		name = "default:fern_" .. length,
+		deco_type = "simple",
+		place_on = {
+			"ethereal:cold_dirt", "default:dirt_with_coniferous_litter"},
+		sidelen = 16,
+		noise_params = {
+			offset = 0,
+			scale = 0.2,
+			spread = {x = 100, y = 100, z = 100},
+			seed = seed,
+			octaves = 3,
+			persist = 0.7
+		},
+		y_max = 31000,
+		y_min = 6,
+		decoration = "default:fern_" .. length,
+	})
+end
+
+register_fern_decoration(14936, 3)
+register_fern_decoration(801, 2)
+register_fern_decoration(5, 1)
+end
+
+
+if ethereal.tundra and minetest.registered_nodes["default:permafrost"] then
+
+	-- Tundra moss
+
+	minetest.register_decoration({
+		deco_type = "simple",
+		place_on = {"default:permafrost_with_stones"},
+		sidelen = 4,
+		noise_params = {
+			offset = -0.8,
+			scale = 2.0,
+			spread = {x = 100, y = 100, z = 100},
+			seed = 53995,
+			octaves = 3,
+			persist = 1.0
+		},
+		biomes = {"tundra"},
+		y_max = 50,
+		y_min = 2,
+		decoration = "default:permafrost_with_moss",
+		place_offset_y = -1,
+		flags = "force_placement",
+	})
+
+	-- Tundra patchy snow
+
+	minetest.register_decoration({
+		deco_type = "simple",
+		place_on = {
+			"default:permafrost_with_moss",
+			"default:permafrost_with_stones",
+			"default:stone",
+			"default:gravel"
+		},
+		sidelen = 4,
+		noise_params = {
+			offset = 0,
+			scale = 1.0,
+			spread = {x = 100, y = 100, z = 100},
+			seed = 172555,
+			octaves = 3,
+			persist = 1.0
+		},
+		biomes = {"tundra", "tundra_beach"},
+		y_max = 50,
+		y_min = 1,
+		decoration = "default:snow",
+	})
+end
+
+
+if minetest.get_modpath("butterflies") then
+minetest.register_decoration({
+	name = "butterflies:butterfly",
+	deco_type = "simple",
+	place_on = {"default:dirt_with_grass", "ethereal:prairie_dirt"},
+	place_offset_y = 2,
+	sidelen = 80,
+	fill_ratio = 0.005,
+	biomes = {"grassy", "grassytwo", "prairie", "jumble"},
+	y_max = 31000,
+	y_min = 1,
+	decoration = {
+		"butterflies:butterfly_white",
+		"butterflies:butterfly_red",
+		"butterflies:butterfly_violet"
+	},
+	spawn_by = "group:flower",
+	num_spawn_by = 1
+})
+end
+
+
+if minetest.get_modpath("fireflies") then
+	minetest.register_decoration({
+		name = "fireflies:firefly_low",
+		deco_type = "simple",
+		place_on = {
+			"default:dirt_with_grass",
+			"default:dirt_with_coniferous_litter",
+			"default:dirt_with_rainforest_litter",
+			"default:dirt",
+			"ethereal:cold_dirt",
+		},
+		place_offset_y = 2,
+		sidelen = 80,
+		fill_ratio = 0.0005,
+		biomes = {"grassy", "grassytwo", "snowy", "junglee", "swamp"},
+		y_max = 31000,
+		y_min = -1,
+		decoration = "fireflies:hidden_firefly",
+	})
+end
+
+
+-- Coral Reef (Minetest 5.0)
+if minetest.registered_nodes["default:coral_green"] then
+	minetest.register_decoration({
+		name = "default:corals",
+		deco_type = "simple",
+		place_on = {"default:sand"},
+		place_offset_y = -1,
+		sidelen = 4,
+		noise_params = {
+			offset = -4,
+			scale = 4,
+			spread = {x = 50, y = 50, z = 50},
+			seed = 7013,
+			octaves = 3,
+			persist = 0.7,
+		},
+		biomes = {
+			"desert_ocean",
+			"savanna_ocean",
+			"junglee_ocean",
+		},
+		y_max = -2,
+		y_min = -8,
+		flags = "force_placement",
+		decoration = {
+			"default:coral_green", "default:coral_pink",
+			"default:coral_cyan", "default:coral_brown",
+			"default:coral_orange", "default:coral_skeleton",
+		},
+	})
+
+	-- Kelp
+
+	minetest.register_decoration({
+		name = "default:kelp",
+		deco_type = "simple",
+		place_on = {"default:sand"},
+		place_offset_y = -1,
+		sidelen = 16,
+		noise_params = {
+			offset = -0.04,
+			scale = 0.1,
+			spread = {x = 200, y = 200, z = 200},
+			seed = 87112,
+			octaves = 3,
+			persist = 0.7
+		},
+		biomes = {
+			"frost_ocean", "grassy_ocean", "sandstone_ocean", "swamp_ocean"},
+		y_max = -5,
+		y_min = -10,
+		flags = "force_placement",
+		decoration = "default:sand_with_kelp",
+		param2 = 48,
+		param2_max = 96,
+	})
+end
+
+
+local random = math.random
+
+-- Generate Illumishroom in caves next to coal
+minetest.register_on_generated(function(minp, maxp)
+
+	if minp.y > -30 or maxp.y < -3000 then
+		return
+	end
+
+	local bpos
+	local coal = minetest.find_nodes_in_area_under_air(
+			minp, maxp, "default:stone_with_coal")
+
+	for n = 1, #coal do
+
+		if random(1, 2) == 1 then
+
+			bpos = {x = coal[n].x, y = coal[n].y + 1, z = coal[n].z }
+
+			if bpos.y > -3000 and bpos.y < -2000 then
+				minetest.swap_node(bpos, {name = "ethereal:illumishroom3"})
+
+			elseif bpos.y > -2000 and bpos.y < -1000 then
+				minetest.swap_node(bpos, {name = "ethereal:illumishroom2"})
+
+			elseif bpos.y > -1000 and bpos.y < -30 then
+				minetest.swap_node(bpos, {name = "ethereal:illumishroom"})
+			end
+		end
+	end
+end)

+ 10 - 0
mods/ethereal/depends.txt

@@ -0,0 +1,10 @@
+default
+farming?
+stairs
+flowers
+doors
+bakedclay?
+moreblocks?
+intllib?
+lucky_block?
+toolranks?

+ 1 - 0
mods/ethereal/description.txt

@@ -0,0 +1 @@
+Ethereal mod uses the v7 mapgen to add many new biomes to the world.

+ 309 - 0
mods/ethereal/dirt.lua

@@ -0,0 +1,309 @@
+
+local S = ethereal.intllib
+
+-- override default dirt (to stop caves cutting away dirt)
+minetest.override_item("default:dirt", {is_ground_content = ethereal.cavedirt})
+
+minetest.register_alias("ethereal:green_dirt", "default:dirt_with_grass")
+
+-- dry dirt
+minetest.register_node("ethereal:dry_dirt", {
+	description = S("Dried Dirt"),
+	tiles = {"ethereal_dry_dirt.png"},
+	is_ground_content = ethereal.cavedirt,
+	groups = {crumbly = 3},
+	sounds = default.node_sound_dirt_defaults()
+})
+
+minetest.register_craft({
+	type = "cooking",
+	output = "ethereal:dry_dirt",
+	recipe = "default:dirt",
+	cooktime = 3,
+})
+
+local dirts = {
+	"Bamboo", "Jungle", "Grove", "Prairie", "Cold",
+	"Crystal", "Mushroom", "Fiery", "Gray"
+}
+
+for n = 1, #dirts do
+
+	local desc = dirts[n]
+	local name = desc:lower()
+
+	minetest.register_node("ethereal:"..name.."_dirt", {
+		description = S(desc.." Dirt"),
+		tiles = {
+			"ethereal_grass_"..name.."_top.png",
+			"default_dirt.png",
+			{
+				name = "default_dirt.png^ethereal_grass_"
+				.. name .."_side.png",
+				tileable_vertical = false
+			}
+		},
+		is_ground_content = ethereal.cavedirt,
+		groups = {crumbly = 3, soil = 1, spreading_dirt_type = 1},
+		soil = {
+			base = "ethereal:"..name.."_dirt",
+			dry = "farming:soil",
+			wet = "farming:soil_wet"
+		},
+		drop = "default:dirt",
+		sounds = default.node_sound_dirt_defaults({
+			footstep = {name = "default_grass_footstep", gain = 0.25},
+		}),
+	})
+
+end
+
+
+-- flower spread, also crystal and fire flower regeneration
+local flower_spread = function(pos, node)
+
+	if (minetest.get_node_light(pos) or 0) < 13 then
+		return
+	end
+
+	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(pos0, pos1, "group:flora")
+
+	-- stop flowers spreading too much just below top of map block
+	if minetest.find_node_near(pos, 2, "ignore") then
+		return
+	end
+
+	if num > 3
+	and node.name == "ethereal:crystalgrass" then
+
+		local grass = minetest.find_nodes_in_area_under_air(
+			pos0, pos1, {"ethereal:crystalgrass"})
+
+		if #grass > 4
+		and not minetest.find_node_near(pos, 4, {"ethereal:crystal_spike"}) then
+
+			pos = grass[math.random(#grass)]
+
+			pos.y = pos.y - 1
+
+			if minetest.get_node(pos).name == "ethereal:crystal_dirt" then
+
+				pos.y = pos.y + 1
+
+				minetest.swap_node(pos, {name = "ethereal:crystal_spike"})
+			end
+		end
+
+		return
+
+	elseif num > 3
+	and node.name == "ethereal:dry_shrub" then
+
+		local grass = minetest.find_nodes_in_area_under_air(
+			pos0, pos1, {"ethereal:dry_shrub"})
+
+		if #grass > 8
+		and not minetest.find_node_near(pos, 4, {"ethereal:fire_flower"}) then
+
+			pos = grass[math.random(#grass)]
+
+			pos.y = pos.y - 1
+
+			if minetest.get_node(pos).name == "ethereal:fiery_dirt" then
+
+				pos.y = pos.y + 1
+
+				minetest.swap_node(pos, {name = "ethereal:fire_flower"})
+			end
+		end
+
+		return
+
+	elseif num > 3 then
+		return
+	end
+
+	local seedling = minetest.find_nodes_in_area_under_air(
+		pos0, pos1, {"group:soil"})
+
+	if #seedling > 0 then
+
+		pos = seedling[math.random(#seedling)]
+
+		-- default farming has desert sand as soil, so dont spread on this
+		if minetest.get_node(pos).name == "default:desert_sand" then
+			return
+		end
+
+		pos.y = pos.y + 1
+
+		if (minetest.get_node_light(pos) or 0) < 13 then
+			return
+		end
+
+		minetest.swap_node(pos, {name = node.name})
+	end
+end
+
+-- grow papyrus up to 4 high and bamboo up to 8 high
+local grow_papyrus = function(pos, node)
+
+	local oripos = pos.y
+	local high = 4
+
+	pos.y = pos.y - 1
+
+	local nod = minetest.get_node_or_nil(pos)
+
+	if not nod
+	or minetest.get_item_group(nod.name, "soil") < 1
+	or minetest.find_node_near(pos, 3, {"group:water"}) == nil then
+		return
+	end
+
+	if node.name == "ethereal:bamboo" then
+		high = 8
+	end
+
+	pos.y = pos.y + 1
+
+	local height = 0
+
+	while height < high
+	and minetest.get_node(pos).name == node.name do
+		height = height + 1
+		pos.y = pos.y + 1
+	end
+
+	nod = minetest.get_node_or_nil(pos)
+
+	if nod
+	and nod.name == "air"
+	and height < high then
+
+		if node.name == "ethereal:bamboo"
+		and height == (high - 1) then
+
+			ethereal.grow_bamboo_tree({x = pos.x, y = oripos, z = pos.z})
+		else
+			minetest.swap_node(pos, {name = node.name})
+		end
+	end
+
+end
+
+-- loop through active abm's
+for _, ab in pairs(minetest.registered_abms) do
+
+	local label = ab.label or ""
+	local node1 = ab.nodenames and ab.nodenames[1] or ""
+	local node2 = ab.nodenames and ab.nodenames[2] or ""
+	local neigh = ab.neighbors and ab.neighbors[1] or ""
+
+	if label == "Flower spread"
+	or node1 == "group:flora" then
+
+		--ab.interval = 1
+		--ab.chance = 1
+		ab.nodenames = {"group:flora"}
+		ab.neighbors = {"group:soil"}
+		ab.action = flower_spread
+
+	-- find grow papyrus abm and change to grow_papyrus function
+	elseif label == "Grow papyrus"
+	or node1 == "default:papyrus" then
+
+		--ab.interval = 2
+		--ab.chance = 1
+		ab.nodenames = {"default:papyrus", "ethereal:bamboo"}
+		ab.neighbors = {"group:soil"}
+		ab.action = grow_papyrus
+	end
+end
+
+-- If Baked Clay mod not active, make Red, Orange and Grey nodes
+if not minetest.get_modpath("bakedclay") then
+
+	minetest.register_node(":bakedclay:red", {
+		description = S("Red Baked Clay"),
+		tiles = {"baked_clay_red.png"},
+		groups = {cracky = 3},
+		is_ground_content = ethereal.cavedirt,
+		sounds = default.node_sound_stone_defaults(),
+	})
+
+	minetest.register_node(":bakedclay:orange", {
+		description = S("Orange Baked Clay"),
+		tiles = {"baked_clay_orange.png"},
+		groups = {cracky = 3},
+		is_ground_content = ethereal.cavedirt,
+		sounds = default.node_sound_stone_defaults(),
+	})
+
+	minetest.register_node(":bakedclay:grey", {
+		description = S("Grey Baked Clay"),
+		tiles = {"baked_clay_grey.png"},
+		groups = {cracky = 3},
+		is_ground_content = ethereal.cavedirt,
+		sounds = default.node_sound_stone_defaults(),
+	})
+
+end
+
+-- Quicksand (old style, sinking inside shows black instead of yellow effect,
+-- works ok with noclip enabled though)
+minetest.register_node("ethereal:quicksand", {
+	description = S("Quicksand"),
+	tiles = {"default_sand.png"},
+	drop = "default:sand",
+	liquid_viscosity = 15,
+	liquidtype = "source",
+	liquid_alternative_flowing = "ethereal:quicksand",
+	liquid_alternative_source = "ethereal:quicksand",
+	liquid_renewable = false,
+	liquid_range = 0,
+	drowning = 1,
+	walkable = false,
+	climbable = false,
+	post_effect_color = {r = 230, g = 210, b = 160, a = 245},
+	groups = {crumbly = 3, sand = 1, liquid = 3, disable_jump = 1},
+	sounds = default.node_sound_sand_defaults(),
+})
+
+-- Quicksand (new style, sinking inside shows yellow effect with or without noclip,
+-- but old quicksand is shown as black until block placed nearby to update light)
+minetest.register_node("ethereal:quicksand2", {
+	description = S("Quicksand"),
+	tiles = {"default_sand.png"},
+	drawtype = "glasslike",
+	paramtype = "light",
+	drop = "default:sand",
+	liquid_viscosity = 15,
+	liquidtype = "source",
+	liquid_alternative_flowing = "ethereal:quicksand2",
+	liquid_alternative_source = "ethereal:quicksand2",
+	liquid_renewable = false,
+	liquid_range = 0,
+	drowning = 1,
+	walkable = false,
+	climbable = false,
+	post_effect_color = {r = 230, g = 210, b = 160, a = 245},
+	groups = {crumbly = 3, sand = 1, liquid = 3, disable_jump = 1},
+	sounds = default.node_sound_sand_defaults(),
+})
+
+-- craft quicksand
+minetest.register_craft({
+	output = "ethereal:quicksand2",
+	recipe = {
+		{"group:sand", "group:sand", "group:sand"},
+		{"group:sand", "bucket:bucket_water", "group:sand"},
+		{"group:sand", "group:sand", "group:sand"},
+	},
+	replacements = {
+		{"bucket:bucket_water", "bucket:bucket_empty"}
+	}
+})

+ 0 - 0
mods/ethereal/extra.lua


Some files were not shown because too many files changed in this diff