I found the problem, in Flare Stack's mod : In file data-final-fixes.lua
line 94
if not (vi.fuel_category and vi.fuel_category == "chemical"
and not fuelGreaterThan(coal_value, vi.fuel_value)) then
When threating the following recipe :
{
flags = {
"goes-to-main-inventory"
},
fuel_category = "chemical",
icon = "__angelspetrochem__/graphics/icons/coal-crushed.png",
name = "coal-crushed",
order = "a[carbon]",
stack_size = 200,
subgroup = "petrochem-raw",
type = "item"
}
Since the recipe don't have a fuel value, when calling fuelGreaterThan(coal_value, vi.fuel_value)
, the second parameter is nil
.
Then is the same file, line 44
local exp2 = fuel_suffix_list[string.sub(fuel2,string.find(fuel2, "%a+"))]
when fuel2 is nil, it throw an error because it should be a string.
I think that a parameter should be checked or before calling the function actually check that it have a fuel value before assuming so.