From 3b587d0b14c895edc35caeb52ec51135786ea489 Mon Sep 17 00:00:00 2001 From: D00Med Date: Sat, 2 Jul 2016 07:19:59 +1000 Subject: [PATCH] Plant improvements >Sunlight passes through plants >Plants can be built over --- init.lua | 48 ++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 46 insertions(+), 2 deletions(-) diff --git a/init.lua b/init.lua index b9f23d8..d442497 100644 --- a/init.lua +++ b/init.lua @@ -9,6 +9,8 @@ minetest.register_node("moreplants:tallgrass", { tiles = {"moreplants_longgrass.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_longgrass.png", visual_scale = 1.4, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -26,6 +28,8 @@ minetest.register_node("moreplants:xlbush", { tiles = {"moreplants_xlbush.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_xlbush.png", visual_scale = 1.4, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -44,6 +48,8 @@ minetest.register_node("moreplants:bulrush", { tiles = {"moreplants_bullrush.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_bullrush.png", visual_scale = 1.3, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -61,6 +67,8 @@ minetest.register_node("moreplants:bigfern", { tiles = {"moreplants_bigfern.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_bigfern.png", visual_scale = 1.5, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -78,6 +86,8 @@ minetest.register_node("moreplants:umbrella", { tiles = {"moreplants_umbrella.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_umbrella.png", visual_scale = 2, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -95,6 +105,8 @@ minetest.register_node("moreplants:bigflower", { tiles = {"moreplants_bigflower.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_bigflower.png", visual_scale = 1.2, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -112,6 +124,8 @@ minetest.register_node("moreplants:weed", { tiles = {"moreplants_weed.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_weed.png", visual_scale = 1.1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -129,6 +143,8 @@ minetest.register_node("moreplants:stoneweed", { tiles = {"moreplants_stoneplant.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_stoneplant.png", visual_scale = 1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -146,6 +162,8 @@ minetest.register_node("moreplants:spikefern", { tiles = {"moreplants_spikefern.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_spikefern.png", visual_scale = 1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -163,6 +181,8 @@ minetest.register_node("moreplants:eyeweed", { tiles = {"moreplants_eyeweed.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_eyeweed.png", visual_scale = 1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -181,6 +201,8 @@ minetest.register_node("moreplants:fern", { tiles = {"moreplants_fern.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_fern.png", visual_scale = 1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -198,6 +220,8 @@ minetest.register_node("moreplants:bush", { tiles = {"moreplants_bush.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_bush.png", visual_scale = 1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -215,6 +239,8 @@ minetest.register_node("moreplants:cactus", { tiles = {"moreplants_cactus.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_cactus.png", visual_scale = 1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -233,6 +259,8 @@ minetest.register_node("moreplants:moonflower", { tiles = {"moreplants_moonflower.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_moonflower.png", visual_scale = 1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -249,8 +277,9 @@ minetest.register_node("moreplants:fireflower", { drawtype = "plantlike", tiles = {"moreplants_fireflower.png"}, paramtype = "light", - light_source = 5, is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_fireflower.png", visual_scale = 1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -269,6 +298,8 @@ minetest.register_node("moreplants:deadweed", { paramtype = "light", light_source = 5, is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_deadweed.png", visual_scale = 1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -287,6 +318,8 @@ minetest.register_node("moreplants:taigabush", { paramtype = "light", light_source = 5, is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_tundrabush.png", visual_scale = 1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -304,6 +337,8 @@ minetest.register_node("moreplants:glowfung", { tiles = {"moreplants_glowfung.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, light_source = 20, legacy_wallmounted = true, selection_box = { @@ -327,6 +362,8 @@ minetest.register_node("moreplants:jungleflower", { tiles = {"moreplants_jungleflower1.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_jungleflower1.png", visual_scale = 1.1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -350,6 +387,9 @@ minetest.register_node("moreplants:mushroom", { }, drawtype = "nodebox", paramtype = "light", + buildable_to = true, + sunlight_propagates = true, + is_ground_content = false, node_box = { type = "fixed", fixed = { @@ -368,6 +408,8 @@ minetest.register_node("moreplants:curly", { tiles = {"moreplants_curly.png"}, paramtype = "light", is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, inventory_image = "moreplants_curly.png", visual_scale = 1.1, wield_scale = {x=0.5, y=0.5, z=0.5}, @@ -393,10 +435,11 @@ minetest.register_node("moreplants:clover", { }, groups = {snappy=3, flammable=1, attatched_node=1}, is_ground_content=true, + buildable_to = true, + sunlight_propagates = true, walkable = false, inventory_image = "moreplants_clover.png", paramtype = "light", - sunlight_propagates=true, selection_box = { type = "fixed", fixed = {-0.5, -0.5, -0.5, 0.5, -0.1, 0.5} @@ -416,6 +459,7 @@ minetest.register_node("moreplants:groundfung", { }, groups = {snappy=3, flammable=1, attatched_node=1}, is_ground_content=true, + buildable_to = true, walkable = false, inventory_image = "moreplants_groundfung.png", paramtype = "light",