From 0d09680184a82c5bb3150c1ef92ec926a10f66a9 Mon Sep 17 00:00:00 2001 From: tacigar Date: Thu, 15 Sep 2016 10:59:12 +0900 Subject: [PATCH] [FIX] Fix spawner --- maidroid/api.lua | 28 ++++++++++++---------------- 1 file changed, 12 insertions(+), 16 deletions(-) diff --git a/maidroid/api.lua b/maidroid/api.lua index 77d0424..f5f4710 100644 --- a/maidroid/api.lua +++ b/maidroid/api.lua @@ -3,8 +3,6 @@ -- https://github.com/tacigar/maidroid ------------------------------------------------------------ -maidroid.debug_mode = true - -- maidroid.animation_frames represents the animation frame data -- of "models/maidroid.b3d". maidroid.animation_frames = { @@ -352,18 +350,16 @@ function maidroid.register_maidroid(product_name, def) }) -- register a spawner for debugging maidroid mods. - if maidroid.debug_mode then - minetest.register_craftitem(product_name .. "_spawner", { - description = product_name .. " spawner", - inventory_image = "maidroid_debug_spawner.png", - stack_max = 1, - on_use = function(item_stack, user, pointed_thing) - if pointed_thing.above ~= nil then - minetest.add_entity(pointed_thing.above, product_name) - return itemstack - end - return nil - end, - }) - end + minetest.register_craftitem(product_name .. "_spawner", { + description = product_name .. " spawner", + inventory_image = def.inventory_image, + stack_max = 1, + on_use = function(item_stack, user, pointed_thing) + if pointed_thing.above ~= nil then + minetest.add_entity(pointed_thing.above, product_name) + return itemstack + end + return nil + end, + }) end