attempt fix
This commit is contained in:
parent
bdce031209
commit
6327eb1db1
3 changed files with 13 additions and 1 deletions
|
|
@ -1,4 +1,9 @@
|
|||
---------------------------------------------------------------------------------------------------
|
||||
Version: 0.2.2
|
||||
Date: 2022-07-06
|
||||
Fixes:
|
||||
- Attempt to fix an issue with duplicate ingredients in refractory recipes
|
||||
---------------------------------------------------------------------------------------------------
|
||||
Version: 0.2.1
|
||||
Date: 2022-07-05
|
||||
Changes:
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "bzfoundry",
|
||||
"version": "0.2.1",
|
||||
"version": "0.2.2",
|
||||
"factorio_version": "1.1",
|
||||
"title": "Foundry",
|
||||
"author": "Brevven",
|
||||
|
|
|
|||
|
|
@ -176,8 +176,15 @@ function make_ingredients_and_products(r, name)
|
|||
if refractory_amount > 25 then refractory_amount = refractory_amount / 25 end
|
||||
end
|
||||
for i, refractory in pairs(refractories) do
|
||||
for j, existing in pairs(r.ingredients) do
|
||||
if existing[1] == refractory or existing.name == refractory then
|
||||
log("Warning: "..name.." refractory recipe recipe unbalanced due to skipped ingredients")
|
||||
goto skip
|
||||
end
|
||||
end
|
||||
table.insert(r.ingredients, {refractory, refractory_amount})
|
||||
end
|
||||
::skip::
|
||||
|
||||
for i, result in pairs(r.results) do
|
||||
if result[1] and check_name(result[1]) then
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue