mirror of
https://git.minetest.land/VoxeLibre/VoxeLibre.git
synced 2024-12-23 00:19:32 +01:00
Don't remove placed flower into flower pot in CM
This commit is contained in:
parent
b7589f5389
commit
9c0a5373f9
1 changed files with 8 additions and 4 deletions
|
@ -55,16 +55,20 @@ minetest.register_node("mcl_flowerpots:flower_pot", {
|
||||||
local flower = row[1]
|
local flower = row[1]
|
||||||
local flower_node = row[2]
|
local flower_node = row[2]
|
||||||
if item == flower_node then
|
if item == flower_node then
|
||||||
minetest.set_node(pos, {name="mcl_flowerpots:flower_pot_"..flower})
|
minetest.swap_node(pos, {name="mcl_flowerpots:flower_pot_"..flower})
|
||||||
itemstack:take_item()
|
if not minetest.setting_getbool("creative_mode") then
|
||||||
|
itemstack:take_item()
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
for _, row in ipairs(cubes) do
|
for _, row in ipairs(cubes) do
|
||||||
local flower = row[1]
|
local flower = row[1]
|
||||||
local flower_node = row[2]
|
local flower_node = row[2]
|
||||||
if item == flower_node then
|
if item == flower_node then
|
||||||
minetest.set_node(pos, {name="mcl_flowerpots:flower_pot_"..flower})
|
minetest.swap_node(pos, {name="mcl_flowerpots:flower_pot_"..flower})
|
||||||
itemstack:take_item()
|
if not minetest.setting_getbool("creative_mode") then
|
||||||
|
itemstack:take_item()
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
|
|
Loading…
Reference in a new issue