Compare commits

...

7 Commits

Author SHA1 Message Date
Nils Dagsson Moskopp fb23a69b88
Reintroduce golem spawning with carved pumpkins 2021-07-31 20:34:39 +02:00
Nils Dagsson Moskopp 09d1540176
Make villagers accept uncarved pumpkin in trades
As map generation and growing mechanics have been changed to generate
uncarved pumpkins instead of carved, requiring players to shear every
pumpkin before trading it with villagers seems like useless busywork.
2021-07-31 20:13:29 +02:00
Nils Dagsson Moskopp aabe4fbdd0
Remove pumpkin pie recipe with carved pumpkin
Shearing an uncarved pumpkin turns it into a carved pumpkin and drops
four pumpkin seeds. As map generation and growing mechanics have been
changed to generate uncarved pumpkins instead of carved, preserving a
recipe to get pumpkin pie from carved pumpkins enabled players to get
both seeds and pumpkin pie from grown pumpkins, which was unintended.
2021-07-31 20:03:17 +02:00
Nils Dagsson Moskopp 15cf859dda
Remove pumpkin seeds recipe with carved pumpkin
Shearing an uncarved pumpkin turns it into a carved pumpkin and drops
four pumpkin seeds. As map generation and growing mechanics have been
changed to generate uncarved pumpkins instead of carved, preserving a
recipe to get seeds from carved pumpkins enables players to get twice
the amount of seeds as intended. Because of this, the recipe must go.
2021-07-31 19:49:10 +02:00
Alexander Minges 27f4ba3466
Use correct location for pumpkin shearing sound
The code for turning an uncarved pumpkin into a carved pumpkin using
the shears was using “above” instead of “pointed_thing.above” as the
location for its sound. This resulted in a warning being logged when
shears were being used on a pumpkin. This patch rectifies the issue.
2021-07-31 18:44:48 +02:00
Alexander Minges 9345287ff3
Grow uncarved pumpkin from seeds instead of carved
Carved pumpkin has to be explicitly registered as a separate
node, as registering a carved pumpkin node was a side effect
of invoking mcl_farming:add_gourd() for the carved pumpkin.
2021-07-31 00:49:08 +02:00
Alexander Minges 3b4ad6dde2
Use uncarved pumpkin instead of carved in mapgen 2021-07-30 22:00:01 +02:00
5 changed files with 11 additions and 20 deletions

View File

@ -74,7 +74,7 @@ local professions = {
},
{
{ { "mcl_farming:pumpkin_face", 8, 13 }, E1 },
{ { "mcl_farming:pumpkin", 8, 13 }, E1 },
{ E1, { "mcl_farming:pumpkin_pie", 2, 3} },
},

View File

@ -115,20 +115,21 @@ pumpkin_face_base_def.groups.armor_head=1
pumpkin_face_base_def._mcl_armor_mob_range_factor = 0
pumpkin_face_base_def._mcl_armor_mob_range_mob = "mobs_mc:enderman"
pumpkin_face_base_def.groups.non_combat_armor=1
pumpkin_face_base_def.on_construct = function(pos)
-- Attempt to spawn iron golem or snow golem
mobs_mc.tools.check_iron_golem_summon(pos)
mobs_mc.tools.check_snow_golem_summon(pos)
end
if minetest.get_modpath("mcl_armor") then
pumpkin_face_base_def.on_secondary_use = armor.on_armor_use
end
minetest.register_node("mcl_farming:pumpkin_face", pumpkin_face_base_def)
-- Register stem growth
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_face_base_def, 30, 15, "mcl_farming_pumpkin_stem_connected.png^[colorize:#FFA800:127",
function(pos)
-- Attempt to spawn iron golem or snow golem
mobs_mc.tools.check_iron_golem_summon(pos)
mobs_mc.tools.check_snow_golem_summon(pos)
end)
mcl_farming:add_gourd("mcl_farming:pumpkintige_unconnect", "mcl_farming:pumpkintige_linked", "mcl_farming:pumpkintige_unconnect", stem_def, stem_drop, "mcl_farming:pumpkin", pumpkin_base_def, 30, 15, "mcl_farming_pumpkin_stem_connected.png^[colorize:#FFA800:127")
-- Jack o'Lantern
minetest.register_node("mcl_farming:pumpkin_face_light", {
@ -165,11 +166,6 @@ minetest.register_craft({
recipe = {{"mcl_farming:pumpkin"}}
})
minetest.register_craft({
output = "mcl_farming:pumpkin_seeds 4",
recipe = {{"mcl_farming:pumpkin_face"}}
})
minetest.register_craftitem("mcl_farming:pumpkin_pie", {
description = S("Pumpkin Pie"),
_doc_items_longdesc = S("A pumpkin pie is a tasty food item which can be eaten."),
@ -187,11 +183,6 @@ minetest.register_craft({
output = "mcl_farming:pumpkin_pie",
recipe = {"mcl_farming:pumpkin", "mcl_core:sugar", "mcl_throwing:egg"},
})
minetest.register_craft({
type = "shapeless",
output = "mcl_farming:pumpkin_pie",
recipe = {"mcl_farming:pumpkin_face", "mcl_core:sugar", "mcl_throwing:egg"},
})
if minetest.get_modpath("doc") then

View File

@ -232,7 +232,7 @@ if minetest.get_modpath("mcl_farming") then
local wear = mcl_autogroup.get_wear(toolname, "shearsy")
itemstack:add_wear(wear)
end
minetest.sound_play({name="default_grass_footstep", gain=1}, {pos = above}, true)
minetest.sound_play({name="default_grass_footstep", gain=1}, {pos = pointed_thing.above}, true)
local dir = vector.subtract(pointed_thing.under, pointed_thing.above)
local param2 = minetest.dir_to_facedir(dir)
minetest.swap_node(pointed_thing.under, {name="mcl_farming:pumpkin_face", param2 = param2})

View File

@ -3532,7 +3532,7 @@ local function register_decorations()
-- Pumpkin
minetest.register_decoration({
deco_type = "simple",
decoration = "mcl_farming:pumpkin_face",
decoration = "mcl_farming:pumpkin",
param2 = 0,
param2_max = 3,
place_on = {"group:grass_block_no_snow"},

View File

@ -868,7 +868,7 @@ local function register_mgv6_decorations()
-- Pumpkin
minetest.register_decoration({
deco_type = "simple",
decoration = "mcl_farming:pumpkin_face",
decoration = "mcl_farming:pumpkin",
param2 = 0,
param2_max = 3,
place_on = {"group:grass_block_no_snow"},