diff --git a/mods/ITEMS/mcl_farming/melon.lua b/mods/ITEMS/mcl_farming/melon.lua index 600e68473f..3a1c27643e 100644 --- a/mods/ITEMS/mcl_farming/melon.lua +++ b/mods/ITEMS/mcl_farming/melon.lua @@ -103,7 +103,7 @@ local stem_def = { mcl_farming:add_plant("plant_melon_stem", "mcl_farming:melontige_unconnect", {"mcl_farming:melontige_1", "mcl_farming:melontige_2", "mcl_farming:melontige_3", "mcl_farming:melontige_4", "mcl_farming:melontige_5", "mcl_farming:melontige_6", "mcl_farming:melontige_7"}, 30, 5) -- Register actual melon, connected stems and stem-to-melon growth -mcl_farming:add_gourd("mcl_farming:melontige_unconnect", "mcl_farming:melontige_linked", "mcl_farming:melontige_unconnect", stem_def, stem_drop, "mcl_farming:melon", melon_base_def, 25, 15) +mcl_farming:add_gourd("mcl_farming:melontige_unconnect", "mcl_farming:melontige_linked", "mcl_farming:melontige_unconnect", stem_def, stem_drop, "mcl_farming:melon", melon_base_def, 25, 15, "mcl_farming_melon_stem_connected.png") -- Items and crafting minetest.register_craftitem("mcl_farming:melon_item", { diff --git a/mods/ITEMS/mcl_farming/pumpkin.lua b/mods/ITEMS/mcl_farming/pumpkin.lua index 4063479e8c..e94ad971e3 100644 --- a/mods/ITEMS/mcl_farming/pumpkin.lua +++ b/mods/ITEMS/mcl_farming/pumpkin.lua @@ -95,9 +95,7 @@ local pumpkin_base_def = { mcl_farming:add_plant("plant_pumpkin_stem", "mcl_farming:pumpkintige_unconnect", {"mcl_farming:pumpkin_1", "mcl_farming:pumpkin_2", "mcl_farming:pumpkin_3", "mcl_farming:pumpkin_4", "mcl_farming:pumpkin_5", "mcl_farming:pumpkin_6", "mcl_farming:pumpkin_7"}, 30, 5) -- Register actual pumpkin, connected stems and stem-to-pumpkin growth -mcl_farming:add_gourd("mcl_farming:pumpkintige_unconnect", "mcl_farming:pumpkintige_linked", "mcl_farming:pumpkintige_unconnect", stem_def, stem_drop, "mcl_farming:pumpkin_face", pumpkin_base_def, 30, 15) - - +mcl_farming:add_gourd("mcl_farming:pumpkintige_unconnect", "mcl_farming:pumpkintige_linked", "mcl_farming:pumpkintige_unconnect", stem_def, stem_drop, "mcl_farming:pumpkin_face", pumpkin_base_def, 30, 15, "mcl_farming_pumpkin_stem_connected.png") -- Jack o'Lantern minetest.register_node("mcl_farming:pumpkin_face_light", { diff --git a/mods/ITEMS/mcl_farming/shared_functions.lua b/mods/ITEMS/mcl_farming/shared_functions.lua index afab966628..c19bb57008 100644 --- a/mods/ITEMS/mcl_farming/shared_functions.lua +++ b/mods/ITEMS/mcl_farming/shared_functions.lua @@ -107,9 +107,10 @@ end - gourd_def: (almost) full definition of the gourd node. This function will add after_dig_node to the definition for unconnecting any connected stems - grow_interval: Will attempt to grow a gourd periodically at this interval in seconds - grow_chance: Chance of 1/grow_chance to grow a gourd next to the full unconnected stem after grow_interval has passed. Must be a natural number +- connected_stem_texture: Texture of the connected stem ]] -function mcl_farming:add_gourd(full_unconnected_stem, connected_stem_basename, stem_itemstring, stem_def, stem_drop, gourd_itemstring, gourd_def, grow_interval, grow_chance) +function mcl_farming:add_gourd(full_unconnected_stem, connected_stem_basename, stem_itemstring, stem_def, stem_drop, gourd_itemstring, gourd_def, grow_interval, grow_chance, connected_stem_texture) local connected_stem_names = { connected_stem_basename .. "_r", @@ -226,27 +227,27 @@ function mcl_farming:add_gourd(full_unconnected_stem, connected_stem_basename, s "blank.png", -- bottom "blank.png", -- right "blank.png", -- left - "farming_tige_connect.png", -- back - "farming_tige_connect.png^[transformFX90" --front + connected_stem_texture, -- back + connected_stem_texture.."^[transformFX90" --front }, { "blank.png", --top "blank.png", -- bottom "blank.png", -- right "blank.png", -- left - "farming_tige_connect.png^[transformFX90", --back - "farming_tige_connect.png", -- front + connected_stem_texture.."^[transformFX90", --back + connected_stem_texture, -- front }, { "blank.png", --top "blank.png", -- bottom - "farming_tige_connect.png^[transformFX90", -- right - "farming_tige_connect.png", -- left + connected_stem_texture.."^[transformFX90", -- right + connected_stem_texture, -- left "blank.png", --back "blank.png", -- front }, { "blank.png", --top "blank.png", -- bottom - "farming_tige_connect.png", -- right - "farming_tige_connect.png^[transformFX90", -- left + connected_stem_texture, -- right + connected_stem_texture.."^[transformFX90", -- left "blank.png", --back "blank.png", -- front } diff --git a/mods/ITEMS/mcl_farming/textures/farming_tige_connect.png b/mods/ITEMS/mcl_farming/textures/mcl_farming_melon_stem_connected.png similarity index 100% rename from mods/ITEMS/mcl_farming/textures/farming_tige_connect.png rename to mods/ITEMS/mcl_farming/textures/mcl_farming_melon_stem_connected.png diff --git a/mods/ITEMS/mcl_farming/textures/mcl_farming_pumpkin_stem_connected.png b/mods/ITEMS/mcl_farming/textures/mcl_farming_pumpkin_stem_connected.png new file mode 100644 index 0000000000..e1ae622db0 Binary files /dev/null and b/mods/ITEMS/mcl_farming/textures/mcl_farming_pumpkin_stem_connected.png differ