0
0
Fork 0

Clean up gourd API

This commit is contained in:
Wuzzy 2017-03-13 22:53:49 +01:00
parent 50814a6d5f
commit 7cd7b27d55
3 changed files with 4 additions and 3 deletions

View File

@ -9,7 +9,7 @@
- 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 - 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
]] ]]
function mcl_farming.register_gourd(full_unconnected_stem, connected_stem_basename, stemdrop, gourd_itemstring, gourd_def, grow_interval, grow_chance) function mcl_farming:add_gourd(full_unconnected_stem, connected_stem_basename, stemdrop, gourd_itemstring, gourd_def, grow_interval, grow_chance)
local connected_stem_names = { local connected_stem_names = {
connected_stem_basename .. "_r", connected_stem_basename .. "_r",

View File

@ -116,7 +116,7 @@ minetest.register_node("mcl_farming:melontige_unconnect", {
mcl_farming:add_plant("mcl_farming:melontige_unconnect", {"mcl_farming:melontige_1", "mcl_farming:melontige_2"}, 50, 20) mcl_farming:add_plant("mcl_farming:melontige_unconnect", {"mcl_farming:melontige_1", "mcl_farming:melontige_2"}, 50, 20)
-- Register actual melon, connected stems and stem-to-melon growth -- Register actual melon, connected stems and stem-to-melon growth
mcl_farming.register_gourd("mcl_farming:melontige_unconnect", "mcl_farming:melontige_linked", stemdrop, "mcl_farming:melon", melon_base_def, 25, 15) mcl_farming:add_gourd("mcl_farming:melontige_unconnect", "mcl_farming:melontige_linked", stemdrop, "mcl_farming:melon", melon_base_def, 25, 15)
-- Items and crafting -- Items and crafting
minetest.register_craftitem("mcl_farming:melon_item", { minetest.register_craftitem("mcl_farming:melon_item", {

View File

@ -1,3 +1,4 @@
-- Seeds
minetest.register_craftitem("mcl_farming:pumpkin_seeds", { minetest.register_craftitem("mcl_farming:pumpkin_seeds", {
description = "Pumpkin Seeds", description = "Pumpkin Seeds",
_doc_items_longdesc = "Grows into a pumpkin. Chickens like pumpkin seeds.", _doc_items_longdesc = "Grows into a pumpkin. Chickens like pumpkin seeds.",
@ -105,7 +106,7 @@ local pumpkin_base_def = {
mcl_farming:add_plant("mcl_farming:pumpkintige_unconnect", {"mcl_farming:pumpkin_1", "mcl_farming:pumpkin_2"}, 80, 20) mcl_farming:add_plant("mcl_farming:pumpkintige_unconnect", {"mcl_farming:pumpkin_1", "mcl_farming:pumpkin_2"}, 80, 20)
-- Register actual pumpkin, connected stems and stem-to-pumpkin growth -- Register actual pumpkin, connected stems and stem-to-pumpkin growth
mcl_farming.register_gourd("mcl_farming:pumpkintige_unconnect", "mcl_farming:pumpkintige_linked", stemdrop, "mcl_farming:pumpkin_face", pumpkin_base_def, 30, 15) mcl_farming:add_gourd("mcl_farming:pumpkintige_unconnect", "mcl_farming:pumpkintige_linked", stemdrop, "mcl_farming:pumpkin_face", pumpkin_base_def, 30, 15)