Commit 71b2c14a authored by Martin's avatar Martin

Print instead of error on too little material

parent a4469252
......@@ -82,7 +82,8 @@ local function request_raw_material(cost, f_material, f_amount)
local made = 0
local material_remaining = transposer.getFluidInTank(sides[mat['input_side']], 1).amount
if material_remaining < (cost * f_amount) then
error("Too little " .. f_material .. " remaining! Need " .. math.floor((cost * f_amount) - material_remaining) .. "mb for operation")
print("Too little " .. f_material .. " remaining! Need an additional " .. math.floor((cost * f_amount) - material_remaining) .. "mb for operation")
return
end
while made < f_amount do
if not sides[mat['input_side']] then
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment