mirror of
https://github.com/PHIDIAS0303/factorio-mod-PHI.git
synced 2025-12-31 04:11:39 +09:00
.
This commit is contained in:
@@ -1,3 +1,10 @@
|
|||||||
|
---------------------------------------------------------------------------------------------------
|
||||||
|
Version: 3.0.60
|
||||||
|
Date: 2025-02-27
|
||||||
|
|
||||||
|
Changes:
|
||||||
|
- [CL] Generic changes on code.
|
||||||
|
|
||||||
---------------------------------------------------------------------------------------------------
|
---------------------------------------------------------------------------------------------------
|
||||||
Version: 3.0.59
|
Version: 3.0.59
|
||||||
Date: 2025-02-22
|
Date: 2025-02-22
|
||||||
|
|||||||
@@ -10,21 +10,11 @@ if settings.startup['PHI-MB'].value and settings.startup['PHI-MB-ENERGY'].value
|
|||||||
local ml = math.max(settings.startup['PHI-MB-ENERGY-SOLAR-TIER'].value, settings.startup['PHI-MB-ENERGY-POWER-TIER'].value)
|
local ml = math.max(settings.startup['PHI-MB-ENERGY-SOLAR-TIER'].value, settings.startup['PHI-MB-ENERGY-POWER-TIER'].value)
|
||||||
|
|
||||||
for i=1, 7 do
|
for i=1, 7 do
|
||||||
local tn = 'compound-energy-' .. i
|
|
||||||
local prereq
|
|
||||||
|
|
||||||
if i > 1 then
|
|
||||||
prereq = {'compound-energy-' .. (i - 1)}
|
|
||||||
|
|
||||||
else
|
|
||||||
prereq = {'solar-energy', 'advanced-circuit', 'electric-energy-accumulators'}
|
|
||||||
end
|
|
||||||
|
|
||||||
data:extend({{
|
data:extend({{
|
||||||
type = 'technology',
|
type = 'technology',
|
||||||
name = tn,
|
name = 'compound-energy-' .. i,
|
||||||
enabled = (i <= ml),
|
enabled = (i <= ml),
|
||||||
prerequisites = prereq,
|
prerequisites = ((i > 1) and {'compound-energy-' .. (i - 1)}) or {'solar-energy', 'advanced-circuit', 'electric-energy-accumulators'},
|
||||||
effects = {},
|
effects = {},
|
||||||
unit = {
|
unit = {
|
||||||
count = math.floor(75 * (i ^ 2)),
|
count = math.floor(75 * (i ^ 2)),
|
||||||
@@ -69,13 +59,7 @@ if settings.startup['PHI-EQ'].value and settings.startup['PHI-EQ-ARMOR'].value t
|
|||||||
|
|
||||||
for _, v in pairs(armor.resistances) do
|
for _, v in pairs(armor.resistances) do
|
||||||
v.decrease = v.decrease + 10
|
v.decrease = v.decrease + 10
|
||||||
|
v.percent = ((v.percent < 90) and v.percent + 10) or v.percent
|
||||||
if v.percent < 90 then
|
|
||||||
v.percent = v.percent + 10
|
|
||||||
|
|
||||||
else
|
|
||||||
v.decrease = 100
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
armor.order = armor.order .. '2'
|
armor.order = armor.order .. '2'
|
||||||
@@ -129,13 +113,7 @@ if settings.startup['PHI-EQ'].value and settings.startup['PHI-EQ-ARMOR'].value t
|
|||||||
|
|
||||||
for _, v in pairs(armor.resistances) do
|
for _, v in pairs(armor.resistances) do
|
||||||
v.decrease = v.decrease + 10
|
v.decrease = v.decrease + 10
|
||||||
|
v.percent = ((v.percent < 90) and v.percent + 10) or v.percent
|
||||||
if v.percent < 90 then
|
|
||||||
v.percent = v.percent + 10
|
|
||||||
|
|
||||||
else
|
|
||||||
v.decrease = 100
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
armor.order = armor.order .. '2'
|
armor.order = armor.order .. '2'
|
||||||
@@ -189,9 +167,7 @@ if settings.startup['PHI-MI'].value then
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
if settings.startup['PHI-MI-LANDFILL'].value ~= 50 then
|
|
||||||
data.raw.recipe['landfill'].ingredients = {{type = 'item', name = 'stone', amount = settings.startup['PHI-MI-LANDFILL'].value}}
|
data.raw.recipe['landfill'].ingredients = {{type = 'item', name = 'stone', amount = settings.startup['PHI-MI-LANDFILL'].value}}
|
||||||
end
|
|
||||||
|
|
||||||
if settings.startup['PHI-MI-NUCLEAR'].value then
|
if settings.startup['PHI-MI-NUCLEAR'].value then
|
||||||
for _, v in pairs(data.raw['reactor']) do
|
for _, v in pairs(data.raw['reactor']) do
|
||||||
@@ -369,23 +345,18 @@ if (settings.startup['PHI-CT'].value and settings.startup['PHI-CT-TOOL'].value)
|
|||||||
entity.crafting_speed = 1
|
entity.crafting_speed = 1
|
||||||
entity.energy_source = {type = 'void'}
|
entity.energy_source = {type = 'void'}
|
||||||
|
|
||||||
local cc = {'default'}
|
|
||||||
|
|
||||||
if mods['space-age'] then
|
|
||||||
cc = {'default', 'fusion-plasma'}
|
|
||||||
end
|
|
||||||
|
|
||||||
entity.fluid_boxes = {{
|
entity.fluid_boxes = {{
|
||||||
production_type = 'output',
|
production_type = 'output',
|
||||||
pipe_covers = table.deepcopy(entity.fluid_box.pipe_covers),
|
pipe_covers = table.deepcopy(entity.fluid_box.pipe_covers),
|
||||||
volume = 6000,
|
volume = 6000,
|
||||||
pipe_connections = {{
|
pipe_connections = {{
|
||||||
flow_direction = 'output',
|
flow_direction = 'output',
|
||||||
connection_category = cc,
|
connection_category = (mods['space-age'] and {'default', 'fusion-plasma'}) or {'default'},
|
||||||
direction = defines.direction.south,
|
direction = defines.direction.south,
|
||||||
position = {0, 0}
|
position = {0, 0}
|
||||||
}}
|
}}
|
||||||
}}
|
}}
|
||||||
|
|
||||||
entity.fluid_box = nil
|
entity.fluid_box = nil
|
||||||
entity.fluid_boxes_off_when_no_fluid_recipe = false
|
entity.fluid_boxes_off_when_no_fluid_recipe = false
|
||||||
entity.effect_receiver = {uses_module_effects=false, uses_beacon_effects=false}
|
entity.effect_receiver = {uses_module_effects=false, uses_beacon_effects=false}
|
||||||
@@ -822,9 +793,7 @@ if settings.startup['PHI-SA'].value then
|
|||||||
v.mass = 1
|
v.mass = 1
|
||||||
|
|
||||||
for _, v2 in pairs(v.resistances) do
|
for _, v2 in pairs(v.resistances) do
|
||||||
if v2.percent > 98 then
|
v2.percent = (v2.percent > 98 and v2.percent = 98) or v2.percent
|
||||||
v2.percent = 98
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -1552,15 +1521,6 @@ if settings.startup['PHI-CT'].value then
|
|||||||
|
|
||||||
for _, v in pairs(data.raw.fluid) do
|
for _, v in pairs(data.raw.fluid) do
|
||||||
if v.subgroup == 'fluid' and (not data.raw[v.name]) then
|
if v.subgroup == 'fluid' and (not data.raw[v.name]) then
|
||||||
local temp
|
|
||||||
|
|
||||||
if v.max_temperature then
|
|
||||||
temp = v.max_temperature
|
|
||||||
|
|
||||||
else
|
|
||||||
temp = v.default_temperature
|
|
||||||
end
|
|
||||||
|
|
||||||
data:extend({{
|
data:extend({{
|
||||||
type = 'recipe',
|
type = 'recipe',
|
||||||
name = 'pump-' .. v.name,
|
name = 'pump-' .. v.name,
|
||||||
@@ -1568,7 +1528,7 @@ if settings.startup['PHI-CT'].value then
|
|||||||
energy_required = 1,
|
energy_required = 1,
|
||||||
enabled = true,
|
enabled = true,
|
||||||
ingredients = {},
|
ingredients = {},
|
||||||
results = {{type='fluid', name=v.name, amount=16000, temperature=temp}},
|
results = {{type = 'fluid', name = v.name, amount = 16000, temperature=v.max_temperature or v.default_temperature}},
|
||||||
main_product = v.name,
|
main_product = v.name,
|
||||||
hide_from_player_crafting = true,
|
hide_from_player_crafting = true,
|
||||||
allow_productivity = false,
|
allow_productivity = false,
|
||||||
@@ -1743,30 +1703,20 @@ if settings.startup['PHI-CT'].value then
|
|||||||
|
|
||||||
for _, c in pairs(chests) do
|
for _, c in pairs(chests) do
|
||||||
item = table.deepcopy(data.raw['item'][c])
|
item = table.deepcopy(data.raw['item'][c])
|
||||||
|
|
||||||
if c == 'steel-chest' then
|
|
||||||
entity = table.deepcopy(data.raw['container'][c])
|
|
||||||
|
|
||||||
else
|
|
||||||
entity = table.deepcopy(data.raw['logistic-container'][c])
|
|
||||||
end
|
|
||||||
|
|
||||||
item.name = 'basic-' .. c
|
item.name = 'basic-' .. c
|
||||||
item.place_result = item.name
|
item.place_result = item.name
|
||||||
item.order = 'b[storage]-h[basic-' .. c .. ']'
|
item.order = 'b[storage]-h[basic-' .. c .. ']'
|
||||||
item.localised_name = {'name.basic-' .. c}
|
item.localised_name = {'name.basic-' .. c}
|
||||||
data:extend({item})
|
data:extend({item})
|
||||||
|
|
||||||
|
entity = (c == 'steel-chest' and table.deepcopy(data.raw['container'][c])) or table.deepcopy(data.raw['logistic-container'][c])
|
||||||
entity.name = item.name
|
entity.name = item.name
|
||||||
entity.minable.result = item.name
|
entity.minable.result = item.name
|
||||||
entity.inventory_type = 'with_filters_and_bar'
|
entity.inventory_type = 'with_filters_and_bar'
|
||||||
entity.inventory_size = 1
|
entity.inventory_size = 1
|
||||||
entity.quality_affects_inventory_size = false
|
entity.quality_affects_inventory_size = false
|
||||||
|
entity.max_logistic_slots = (c == 'steel-chest' and nil) or 1
|
||||||
if c ~= 'steel-chest' then
|
entity.trash_inventory_size = (c == 'steel-chest' and nil) or 1
|
||||||
entity.max_logistic_slots = 1
|
|
||||||
entity.trash_inventory_size = 1
|
|
||||||
end
|
|
||||||
|
|
||||||
entity.localised_name = item.localised_name
|
entity.localised_name = item.localised_name
|
||||||
data:extend({entity})
|
data:extend({entity})
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
{
|
{
|
||||||
"name": "PHI-CL",
|
"name": "PHI-CL",
|
||||||
"version": "3.0.59",
|
"version": "3.0.60",
|
||||||
"factorio_version": "2.0",
|
"factorio_version": "2.0",
|
||||||
"date": "2025-02-22",
|
"date": "2025-02-27",
|
||||||
"title": "Phidias Collection",
|
"title": "Phidias Collection",
|
||||||
"author": "PHIDIAS0303",
|
"author": "PHIDIAS0303",
|
||||||
"contributers": "",
|
"contributers": "",
|
||||||
|
|||||||
Reference in New Issue
Block a user