Merge pull request 'Stop consuming bamboo item when placement is invalid' (#3829) from seventeenthShulker/MineClone2:bamboo_disappearing into master
Reviewed-on: MineClone2/MineClone2#3829 Reviewed-by: ancientmarinerdev <ancientmariner_dev@proton.me>
This commit is contained in:
commit
2ff98f0d27
|
@ -203,11 +203,11 @@ local bamboo_def = {
|
||||||
if node_above_name ~= "mcl_core:water_source" and node_above_name ~= "mcl_core:lava_source"
|
if node_above_name ~= "mcl_core:water_source" and node_above_name ~= "mcl_core:lava_source"
|
||||||
and node_above_name ~= "mcl_nether:nether_lava_source" then
|
and node_above_name ~= "mcl_nether:nether_lava_source" then
|
||||||
local _, position = minetest.item_place(place_item, placer, pointed_thing, fdir)
|
local _, position = minetest.item_place(place_item, placer, pointed_thing, fdir)
|
||||||
|
if position then
|
||||||
if not minetest.is_creative_enabled(placer:get_player_name()) then
|
if not minetest.is_creative_enabled(placer:get_player_name()) then
|
||||||
itemstack:take_item(1)
|
itemstack:take_item(1)
|
||||||
end
|
end
|
||||||
if rand_height and rand_height > 1 then
|
if rand_height and rand_height > 1 then
|
||||||
if position then
|
|
||||||
mcl_bamboo.mcl_log("Setting Height Data...")
|
mcl_bamboo.mcl_log("Setting Height Data...")
|
||||||
meta = minetest.get_meta(position)
|
meta = minetest.get_meta(position)
|
||||||
if meta then
|
if meta then
|
||||||
|
|
Loading…
Reference in New Issue