remove add_titanium_prerequisite
This commit is contained in:
parent
9d2bb61d29
commit
2b9b99f60d
4 changed files with 6 additions and 24 deletions
15
me.lua
15
me.lua
|
|
@ -20,10 +20,6 @@ function me.add_titanium_ingredient(amount, name)
|
|||
add_ingredient(name, me.titanium_plate, amount)
|
||||
end
|
||||
|
||||
function me.add_titanium_prerequisite(name)
|
||||
add_prerequisite(name, me.titanium_processing)
|
||||
end
|
||||
|
||||
function me.get_setting(name)
|
||||
if settings.startup[name] == nil then
|
||||
return nil
|
||||
|
|
@ -48,17 +44,6 @@ end
|
|||
-- TODO These helpers are all duplicates, remove them
|
||||
--
|
||||
|
||||
function add_prerequisite(technology_name, prerequisite)
|
||||
technology = data.raw.technology[technology_name]
|
||||
if technology and data.raw.technology[prerequisite] then
|
||||
if technology.prerequisites then
|
||||
table.insert(technology.prerequisites, prerequisite)
|
||||
else
|
||||
technology.prerequisites = {prerequisite}
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function add_ingredient(recipe_name, ingredient, quantity)
|
||||
if me.bypass[recipe_name] then return end
|
||||
if data.raw.recipe[recipe_name] and data.raw.item[ingredient] then
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ end
|
|||
|
||||
if mods["Hovercrafts"] or mods["Hovercrafts_Realism"] then
|
||||
util.replace_ingredient("hcraft-recipe", "steel-plate", "titanium-plate")
|
||||
util.me.add_titanium_prerequisite("hcraft-tech")
|
||||
util.add_prerequisite("hcraft-tech", util.me.titanium_processing)
|
||||
end
|
||||
|
||||
if mods["Raven"] then
|
||||
|
|
@ -50,7 +50,7 @@ if mods["fast_trans"] then
|
|||
}) do
|
||||
util.replace_ingredient(item, "steel-plate", "titanium-plate")
|
||||
end
|
||||
util.me.add_titanium_prerequisite("fast-one-tech-mk2")
|
||||
util.add_prerequisite("fast-one-tech-mk2", util.me.titanium_processing)
|
||||
end
|
||||
|
||||
-- Just a general compatiblity improvement with py alien life enabled alongside jetpack or other equipment mods
|
||||
|
|
|
|||
|
|
@ -61,6 +61,6 @@ if mods["space-exploration"] then
|
|||
})
|
||||
table.insert(data.raw.technology["se-processing-vulcanite"].effects,
|
||||
{type = "unlock-recipe", recipe= "titanium-smelting-vulcanite"})
|
||||
util.me.add_titanium_prerequisite(data.raw.technology["se-processing-vulcanite"])
|
||||
util.add_prerequisite(data.raw.technology["se-processing-vulcanite"], util.me.titanium_processing)
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -25,13 +25,13 @@ if mods["modmashsplintergold"] then
|
|||
end
|
||||
|
||||
if not mods["bobrevamp"] then
|
||||
util.me.add_titanium_prerequisite("low-density-structure")
|
||||
util.add_prerequisite("low-density-structure", util.me.titanium_processing)
|
||||
end
|
||||
|
||||
|
||||
if (not mods["bobplates"]) then
|
||||
util.replace_ingredient("flying-robot-frame", "steel-plate", "titanium-plate")
|
||||
util.me.add_titanium_prerequisite("robotics")
|
||||
util.add_prerequisite("robotics", util.me.titanium_processing)
|
||||
end
|
||||
|
||||
if (mods["bobrevamp"] and not mods["bobplates"] and not mods["angelssmelting"]) then
|
||||
|
|
@ -40,9 +40,6 @@ if (mods["bobrevamp"] and not mods["bobplates"] and not mods["angelssmelting"])
|
|||
util.replace_ingredient("flying-robot-frame-4", "steel-plate", "titanium-plate")
|
||||
end
|
||||
|
||||
|
||||
|
||||
|
||||
if data.raw.recipe["se-space-pipe"] then
|
||||
-- Space Exploration space stuff
|
||||
util.replace_ingredient("se-space-pipe", "steel-plate", "titanium-plate")
|
||||
|
|
@ -121,7 +118,7 @@ if data.raw.item["underwater-pipe"] then
|
|||
table.remove(data.raw.technology["underwater-pipes"].prerequisites, index)
|
||||
end
|
||||
end
|
||||
util.me.add_titanium_prerequisite("underwater-pipes")
|
||||
util.add_prerequisite("underwater-pipes", util.me.titanium_processing)
|
||||
|
||||
util.replace_ingredient("underwater-pipe", "steel-plate", "titanium-plate")
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue