diff options
Diffstat (limited to 'init.lua')
-rwxr-xr-x | init.lua | 99 |
1 files changed, 98 insertions, 1 deletions
@@ -51,8 +51,17 @@ drawers.enable_1x1 = not core.setting_getbool("drawers_disable_1x1") drawers.enable_1x2 = not core.setting_getbool("drawers_disable_1x2") drawers.enable_2x2 = not core.setting_getbool("drawers_disable_2x2") + +-- +-- GUI +-- + +drawers.gui_bg = "bgcolor[#080808BB;true]" +drawers.gui_bg_img = "background[5,5;1,1;gui_formbg.png;true]" +drawers.gui_slots = "listcolors[#00000069;#5A5A5A;#141318;#30434C;#FFF]" + -- --- Load files +-- Load API -- dofile(MP .. "/lua/helpers.lua") @@ -230,3 +239,91 @@ else }) end + +-- +-- Register drawer upgrades +-- + +if core.get_modpath("default") and default then + drawers.register_drawer_upgrade("drawers:upgrade_steel", { + description = S("Steel Drawer Upgrade (x2)"), + inventory_image = "drawers_upgrade_steel.png", + groups = {drawer_upgrade = 100}, + recipe_item = "default:steel_ingot" + }) + + drawers.register_drawer_upgrade("drawers:upgrade_gold", { + description = S("Gold Drawer Upgrade (x3)"), + inventory_image = "drawers_upgrade_gold.png", + groups = {drawer_upgrade = 200}, + recipe_item = "default:gold_ingot" + }) + + drawers.register_drawer_upgrade("drawers:upgrade_obsidian", { + description = S("Obsidian Drawer Upgrade (x5)"), + inventory_image = "drawers_upgrade_obsidian.png", + groups = {drawer_upgrade = 400}, + recipe_item = "default:obsidian" + }) + + drawers.register_drawer_upgrade("drawers:upgrade_diamond", { + description = S("Diamond Drawer Upgrade (x8)"), + inventory_image = "drawers_upgrade_diamond.png", + groups = {drawer_upgrade = 700}, + recipe_item = "default:diamond" + }) +elseif core.get_modpath("mcl_core") and mcl_core then + drawers.register_drawer_upgrade("drawers:upgrade_iron", { + description = S("Iron Drawer Upgrade (x2)"), + inventory_image = "drawers_upgrade_iron.png", + groups = {drawer_upgrade = 100}, + recipe_item = "mcl_core:iron_ingot" + }) + + drawers.register_drawer_upgrade("drawers:upgrade_gold", { + description = S("Gold Drawer Upgrade (x3)"), + inventory_image = "drawers_upgrade_gold.png", + groups = {drawer_upgrade = 200}, + recipe_item = "mcl_core:gold_ingot" + }) + + drawers.register_drawer_upgrade("drawers:upgrade_obsidian", { + description = S("Obsidian Drawer Upgrade (x5)"), + inventory_image = "drawers_upgrade_obsidian.png", + groups = {drawer_upgrade = 400}, + recipe_item = "mcl_core:obsidian" + }) + + drawers.register_drawer_upgrade("drawers:upgrade_diamond", { + description = S("Diamond Drawer Upgrade (x8)"), + inventory_image = "drawers_upgrade_diamond.png", + groups = {drawer_upgrade = 700}, + recipe_item = "mcl_core:diamond" + }) + + drawers.register_drawer_upgrade("drawers:upgrade_emerald", { + description = S("Emerald Drawer Upgrade (x13)"), + inventory_image = "drawers_upgrade_emerald.png", + groups = {drawer_upgrade = 1200}, + recipe_item = "mcl_core:emerald" + }) +end + + +-- +-- Register drawer upgrade template +-- + +core.register_craftitem("drawers:upgrade_template", { + description = S("Drawer Upgrade Template"), + inventory_image = "drawers_upgrade_template.png" +}) + +core.register_craft({ + output = "drawers:upgrade_template 4", + recipe = { + {"group:stick", "group:stick", "group:stick"}, + {"group:stick", "group:drawer", "group:stick"}, + {"group:stick", "group:stick", "group:stick"} + } +}) |