From 3d82a7133985a5ca080bc5d72a573147a8a838ce Mon Sep 17 00:00:00 2001 From: PHIDIAS <10016767+PHIDIAS0303@users.noreply.github.com> Date: Sat, 18 Mar 2023 16:44:22 +0900 Subject: [PATCH] Update main.lua --- PHI-MB/main.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/PHI-MB/main.lua b/PHI-MB/main.lua index 2e6f6e3..230e90f 100644 --- a/PHI-MB/main.lua +++ b/PHI-MB/main.lua @@ -326,12 +326,12 @@ for i=1, #recipe_list, 1 do end end -for _, tech in pairs(data.raw.technology) do - for k, _ in pairs(tech.effects) do - if tech.effects[k].type == 'unlock-recipe' then - if data.raw.recipe[tech.effects[k].recipe] ~= nil then +for t, _ in pairs(data.raw.technology) do + for k, _ in pairs(data.raw.technology[t].effects) do + if data.raw.technology[t].effects[k].type == 'unlock-recipe' then + if data.raw.recipe[data.raw.technology[t].effects[k].recipe] ~= nil then for j=1, #recipe_multiplier, 1 do - table.insert(tech.effects, {type='unlock-recipe', recipe= tech.effects[k].recipe .. '-' .. j}) + table.insert(data.raw.technology[t].effects, {type='unlock-recipe', recipe= data.raw.technology[t].effects[k].recipe .. '-' .. j}) end end end