forked from mtcontrib/maidroid
Fix
This commit is contained in:
parent
cc60e9ae17
commit
c03a8ded8b
4
api.lua
4
api.lua
@ -149,8 +149,12 @@ function maidroid.register_maidroid(product_name, def)
|
|||||||
inventory_image = def.inventory_image,
|
inventory_image = def.inventory_image,
|
||||||
stack_max = 1,
|
stack_max = 1,
|
||||||
on_use = function(itemstack, user, pointed_thing)
|
on_use = function(itemstack, user, pointed_thing)
|
||||||
|
print(pointed_thing.under, pointed_thing.above)
|
||||||
|
if pointed_thing.above ~= nil then
|
||||||
minetest.add_entity(pointed_thing.above, product_name)
|
minetest.add_entity(pointed_thing.above, product_name)
|
||||||
return itemstack
|
return itemstack
|
||||||
end
|
end
|
||||||
|
return nil
|
||||||
|
end
|
||||||
})
|
})
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user