forked from mrkubax10/industrialtest
feat: support for simple machines
This commit is contained in:
@@ -453,7 +453,7 @@ local function craftResultProxy(method,item)
|
||||
time=output.time,
|
||||
src=after.items[1]
|
||||
}
|
||||
elseif method=="industrialtest.macerating" then
|
||||
elseif method==industrialtest.api.craftingMethods.macerating then
|
||||
local output=industrialtest.api.getMaceratorRecipeResult(item:get_name())
|
||||
if not output then
|
||||
return {
|
||||
@@ -469,7 +469,7 @@ local function craftResultProxy(method,item)
|
||||
time=output.time,
|
||||
src=srcAfter
|
||||
}
|
||||
elseif method=="industrialtest.compressing" then
|
||||
elseif method==industrialtest.api.craftingMethods.compressing then
|
||||
local output=industrialtest.api.getCompressorRecipeResult(item:get_name())
|
||||
if not output or item:get_count()<output.count then
|
||||
return {
|
||||
@@ -485,7 +485,7 @@ local function craftResultProxy(method,item)
|
||||
time=output.time,
|
||||
src=srcAfter
|
||||
}
|
||||
elseif method=="industrialtest.extracting" then
|
||||
elseif method==industrialtest.api.craftingMethods.extracting then
|
||||
local output=industrialtest.api.getExtractorRecipeResult(item:get_name())
|
||||
if not output then
|
||||
return {
|
||||
@@ -501,7 +501,7 @@ local function craftResultProxy(method,item)
|
||||
time=output.time,
|
||||
src=srcAfter
|
||||
}
|
||||
elseif method=="industrialtest.recycling" then
|
||||
elseif method==industrialtest.api.craftingMethods.recycling then
|
||||
local srcAfter=ItemStack(item:get_name())
|
||||
srcAfter:set_count(item:get_count()-1)
|
||||
return {
|
||||
@@ -509,7 +509,7 @@ local function craftResultProxy(method,item)
|
||||
time=2,
|
||||
src=srcAfter
|
||||
}
|
||||
elseif method=="industrialtest.cable_forming" then
|
||||
elseif method==industrialtest.api.craftingMethods.cableForming then
|
||||
local output=industrialtest.api.getCableFormerRecipeResult(item:get_name())
|
||||
if not output then
|
||||
return {
|
||||
@@ -525,7 +525,7 @@ local function craftResultProxy(method,item)
|
||||
time=output.time,
|
||||
src=srcAfter
|
||||
}
|
||||
elseif method=="industrialtest.mass_fabricating" then
|
||||
elseif method==industrialtest.api.craftingMethods.massFabricating then
|
||||
if item:get_count()<34 then
|
||||
return {
|
||||
item=ItemStack(),
|
||||
|
||||
Reference in New Issue
Block a user