Fix fishbuckets placing water in the nether

This commit is contained in:
cora 2022-11-27 00:17:13 +01:00
parent f14bfdc0cd
commit efdd22d69f
1 changed files with 4 additions and 2 deletions

View File

@ -29,6 +29,10 @@ local function on_place_fish(itemstack, placer, pointed_thing)
elseif n.name == "mclx_core:river_water_flowing" then
water = nil
end
if mcl_worlds.pos_to_dimension(pos) == "nether" then
water = nil
minetest.sound_play("fire_extinguish_flame", {pos = pos, gain = 0.25, max_hear_distance = 16}, true)
end
if water then
minetest.set_node(pos,{name = water})
end
@ -53,8 +57,6 @@ for techname, fishname in pairs(fish_names) do
on_place = on_place_fish,
on_secondary_use = on_place_fish,
_on_dispense = function(stack, pos, droppos, dropnode, dropdir)
local buildable = minetest.registered_nodes[dropnode.name].buildable_to or dropnode.name == "mcl_portals:portal"
if not buildable then return stack end
return on_place_fish(stack, nil, {above=droppos})
end,
})