From a1e53fa1295bde067b2ac73e9f0c20b1db15c8f2 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Mon, 20 Nov 2017 05:37:04 +0100 Subject: [PATCH] Use dry grass blocks in the Nether --- mods/ITEMS/mcl_core/nodes_base.lua | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/mods/ITEMS/mcl_core/nodes_base.lua b/mods/ITEMS/mcl_core/nodes_base.lua index d686516ae2..726283f6b1 100644 --- a/mods/ITEMS/mcl_core/nodes_base.lua +++ b/mods/ITEMS/mcl_core/nodes_base.lua @@ -309,8 +309,17 @@ minetest.register_node("mcl_core:dirt_with_grass", { footstep = {name="default_grass_footstep", gain=0.4}, }), on_construct = function(pos) - local found_node = minetest.find_node_near(pos, 1, {"mcl_core:dirt_with_dry_grass", "mcl_core:dirt_with_dry_grass_snow"}) - if found_node then + local _, dim = mcl_util.y_to_layer(pos.y) + local dry + if dim == "nether" then + dry = true + else + local found_node = minetest.find_node_near(pos, 1, {"mcl_core:dirt_with_dry_grass", "mcl_core:dirt_with_dry_grass_snow"}) + if found_node then + dry = true + end + end + if dry then minetest.set_node(pos, {name="mcl_core:dirt_with_dry_grass"}) end return mcl_core.on_snowable_construct(pos)