forked from cacklingfiend/bzgold2
Fixing K2 matter stuff (#1)
Fixed K2 matter generation Fixed Matter tech icon size Sadly the matter conversion recipe icons are not fixed, because the K2 routine doesn't like the 128px icons Check if Matter recipes already exist, error with Them Thar Hills  Co-authored-by: pla Reviewed-on: cacklingfiend/bzgold2#1 Co-authored-by: pla <pla@noreply.example.org> Co-committed-by: pla <pla@noreply.example.org>
This commit is contained in:
parent
7e782eb269
commit
8db4982e5b
4 changed files with 41 additions and 35 deletions
|
|
@ -115,12 +115,12 @@ end
|
|||
function util.k2matter(params)
|
||||
local matter = require("__Krastorio2__/prototypes/libraries/matter")
|
||||
if mods["space-exploration"] then
|
||||
params.k2matter.need_stabilizer = true
|
||||
params.k2matter.needs_stabilizer = true
|
||||
end
|
||||
if not params.k2matter.minimum_conversion_quantity then
|
||||
params.k2matter.minimum_conversion_quantity = 10
|
||||
end
|
||||
if not data.raw.technology[params.k2matter.unlocked_by_technology] then
|
||||
if not data.raw.technology[params.k2matter.unlocked_by] then
|
||||
local icon = ""
|
||||
if params.k2baseicon then
|
||||
icon = util.k2assets().."/technologies/matter-"..params.k2baseicon..".png"
|
||||
|
|
@ -132,7 +132,7 @@ function util.k2matter(params)
|
|||
{
|
||||
{
|
||||
type = "technology",
|
||||
name = params.k2matter.unlocked_by_technology,
|
||||
name = params.k2matter.unlocked_by,
|
||||
icons =
|
||||
{
|
||||
{
|
||||
|
|
@ -163,11 +163,16 @@ function util.k2matter(params)
|
|||
},
|
||||
time = 45,
|
||||
},
|
||||
localised_name = {"technology-name.k2-conversion", {"item-name."..params.k2matter.item_name}},
|
||||
effects = {},
|
||||
-- localised_name = {"technology-name.k2-conversion", {"item-name."..params.k2matter.item_name}},
|
||||
},
|
||||
})
|
||||
end
|
||||
matter.make_recipes(params.k2matter)
|
||||
if params.k2matter.only_deconversion then
|
||||
matter.make_deconversion_recipe(params.k2matter)
|
||||
else
|
||||
matter.make_recipes(params.k2matter)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue