1
0
Fork 0

[mcl_dispensers] fix warnings

doc-refactoring^2
AFCMS 2021-05-23 11:50:16 +02:00
parent b814fe47f9
commit d43b2149e6
1 changed files with 101 additions and 99 deletions

View File

@ -96,7 +96,8 @@ local dispenserdef = {
end, end,
_mcl_blast_resistance = 3.5, _mcl_blast_resistance = 3.5,
_mcl_hardness = 3.5, _mcl_hardness = 3.5,
mesecons = {effector = { mesecons = {
effector = {
-- Dispense random item when triggered -- Dispense random item when triggered
action_on = function (pos, node) action_on = function (pos, node)
local meta = minetest.get_meta(pos) local meta = minetest.get_meta(pos)
@ -166,7 +167,7 @@ local dispenserdef = {
elseif igroups.spawn_egg then elseif igroups.spawn_egg then
-- Spawn mob -- Spawn mob
if not dropnodedef.walkable then if not dropnodedef.walkable then
pointed_thing = { above = droppos, under = { x=droppos.x, y=droppos.y-1, z=droppos.z } } --pointed_thing = { above = droppos, under = { x=droppos.x, y=droppos.y-1, z=droppos.z } }
minetest.add_entity(droppos, stack:get_name()) minetest.add_entity(droppos, stack:get_name())
stack:take_item() stack:take_item()
@ -214,7 +215,8 @@ local dispenserdef = {
end end
end, end,
rules = mesecon.rules.alldirs, rules = mesecon.rules.alldirs,
}}, },
},
on_rotate = on_rotate, on_rotate = on_rotate,
} }