From 8cb84f736cc310be8ae93816dc0e4d0e20d8c977 Mon Sep 17 00:00:00 2001 From: "Tai @ Flex" Date: Sun, 28 Aug 2016 04:19:23 +0100 Subject: [PATCH] specify dependencies, add recipes for inbox, steel --- tincraft/depends.txt | 2 ++ tincraft/init.lua | 56 ++++++++++++++++++++++++++++++++++---------- 2 files changed, 45 insertions(+), 13 deletions(-) diff --git a/tincraft/depends.txt b/tincraft/depends.txt index 87ab2ff..01502ec 100644 --- a/tincraft/depends.txt +++ b/tincraft/depends.txt @@ -1,2 +1,4 @@ default moreores +inbox? +protector? diff --git a/tincraft/init.lua b/tincraft/init.lua index ea05d10..8844ed5 100644 --- a/tincraft/init.lua +++ b/tincraft/init.lua @@ -1,7 +1,16 @@ --some crafts to make tin less useless. +tincraft = {} + local tin = "moreores:tin_ingot" -local dstone = "default:desert_stone" +local s_tin = "tincraft:strong_tin" + +-- Make a more valuable tin product + +minetest.register_craftitem("tincraft:strong_tin", { + description = "Strengthened tin", + inventory_image = "moreores_tin_ingot.png^[colorize:yellow:30" +}) core.register_craft({ output = "tincraft:strong_tin", @@ -12,14 +21,33 @@ core.register_craft({ } }) +-- For those who have not been able to mine iron/are afraid of the first mining trip. +-- Making steel from tin is deliberately laborious. + core.register_craft({ - output = "tincraft:softlock", - type = "cooking", - cooktime = 20, - recipe = "tincraft:strong_tin" + output = "default:steel_ingot", + type = "shapeless", + recipe = { + s_tin,s_tin,s_tin,s_tin,s_tin,s_tin,"default:stone","default:stone","default:stone", + } }) + if minetest.get_modpath("protector") then + local dstone = "default:desert_stone" + + minetest.register_craftitem("tincraft:softlock", { + description = "Malleable Lock", + inventory_image = "protector_logo.png^[colorize:blue:60" + }) + + core.register_craft({ + output = "tincraft:softlock", + type = "cooking", + cooktime = 20, + recipe = "tincraft:strong_tin" + }) + core.register_craft({ output = "protector:protect2", recipe = { @@ -29,14 +57,16 @@ if minetest.get_modpath("protector") then } }) - minetest.register_craftitem("tincraft:softlock", { - description = "Malleable Lock", - inventory_image = "protector_logo.png^[colorize:blue:60" +end + +if minetest.get_modpath("inbox") then + core.register_craft({ + output = "inbox:empty", + recipe = { + {"",s_tin,""}, + {s_tin,"",s_tin}, + {s_tin,s_tin,s_tin}, + } }) end -minetest.register_craftitem("tincraft:strong_tin", { - description = "Strengthened tin", - inventory_image = "moreores_tin_ingot.png^[colorize:yellow:30" -}) -