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,17 +1,5 @@
|
||||
local items = {
|
||||
['setting'] = {
|
||||
['PHI-EN-SOLAR'] = {
|
||||
type = 'enabled',
|
||||
effect = {'solar-panel', 'accumulator'}
|
||||
},
|
||||
['PHI-EN-STEAM'] = {
|
||||
type = 'enabled',
|
||||
effect = {'boiler', 'steam-engine'}
|
||||
},
|
||||
['PHI-EN-NUCLEAR'] = {
|
||||
type = 'enabled',
|
||||
effect = {'nuclear-reactor', 'heat-pipe', 'heat-exchanger', 'steam-turbine'}
|
||||
},
|
||||
['PHI-EN-SOLAR-TIER'] = {
|
||||
type = 'max',
|
||||
effect = {'solar-panel', 'accumulator'}
|
||||
|
||||
@@ -2,6 +2,10 @@ local items = require 'config'
|
||||
|
||||
for k, v in pairs(items['setting']) do
|
||||
for k2=1, #v.effect do
|
||||
if settings.startup[k].value < items[v.effect[k2]].min then
|
||||
items[v.effect[k2]].enabled = false
|
||||
end
|
||||
|
||||
items[v.effect[k2]][v.type] = settings.startup[k].value
|
||||
end
|
||||
end
|
||||
|
||||
@@ -168,6 +168,10 @@ end
|
||||
|
||||
for k, v in pairs(items['setting']) do
|
||||
for k2=1, #v.effect do
|
||||
if settings.startup[k].value < items[v.effect[k2]].min then
|
||||
items[v.effect[k2]].enabled = false
|
||||
end
|
||||
|
||||
items[v.effect[k2]][v.type] = settings.startup[k].value
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
{
|
||||
"name": "PHI-EN",
|
||||
"version": "1.3.3",
|
||||
"version": "1.3.4",
|
||||
"factorio_version": "1.1",
|
||||
"date": "2023-09-18",
|
||||
"date": "2023-09-19",
|
||||
"title": "Phidias Energy",
|
||||
"author": "PHIDIAS0303",
|
||||
"contributers": "",
|
||||
|
||||
@@ -155,9 +155,6 @@ compound-energy-6=Source of free electric energy, but useless at night.
|
||||
compound-energy-7=Source of free electric energy, but useless at night.
|
||||
|
||||
[mod-setting-name]
|
||||
PHI-EN-SOLAR=Solar Panel
|
||||
PHI-EN-STEAM=Steam engine
|
||||
PHI-EN-NUCLEAR=Nuclear reactor
|
||||
PHI-EN-SOLAR-TIER=Solar Panel
|
||||
PHI-EN-STEAM-TIER=Steam engine
|
||||
PHI-EN-NUCLEAR-TIER=Nuclear reactor
|
||||
|
||||
@@ -155,9 +155,6 @@ compound-energy-6=クリーンで燃料が尽きることのない発電設備
|
||||
compound-energy-7=クリーンで燃料が尽きることのない発電設備。夜間は発電しません。
|
||||
|
||||
[mod-setting-name]
|
||||
PHI-EN-SOLAR=ソーラーパネル
|
||||
PHI-EN-STEAM=蒸気機関
|
||||
PHI-EN-NUCLEAR=原子炉
|
||||
PHI-EN-SOLAR-TIER=ソーラーパネル
|
||||
PHI-EN-STEAM-TIER=蒸気機関
|
||||
PHI-EN-NUCLEAR-TIER=原子炉
|
||||
|
||||
@@ -155,9 +155,6 @@ compound-energy-6=取之不盡的電力來源,但在夜晚派不上用場。
|
||||
compound-energy-7=取之不盡的電力來源,但在夜晚派不上用場。
|
||||
|
||||
[mod-setting-name]
|
||||
PHI-EN-SOLAR=太陽能板
|
||||
PHI-EN-STEAM=蒸汽發電機
|
||||
PHI-EN-NUCLEAR=核能反應爐
|
||||
PHI-EN-SOLAR-TIER=太陽能板
|
||||
PHI-EN-STEAM-TIER=蒸汽發電機
|
||||
PHI-EN-NUCLEAR-TIER=核能反應爐
|
||||
|
||||
@@ -155,9 +155,6 @@ compound-energy-6=取之不盡的電力來源,但在夜晚派不上用場。
|
||||
compound-energy-7=取之不盡的電力來源,但在夜晚派不上用場。
|
||||
|
||||
[mod-setting-name]
|
||||
PHI-EN-SOLAR=太陽能板
|
||||
PHI-EN-STEAM=蒸汽發電機
|
||||
PHI-EN-NUCLEAR=核能反應爐
|
||||
PHI-EN-SOLAR-TIER=太陽能板
|
||||
PHI-EN-STEAM-TIER=蒸汽發電機
|
||||
PHI-EN-NUCLEAR-TIER=核能反應爐
|
||||
|
||||
@@ -1,40 +1,22 @@
|
||||
data:extend({{
|
||||
type = 'bool-setting',
|
||||
name = 'PHI-EN-SOLAR',
|
||||
setting_type = 'startup',
|
||||
default_value = true,
|
||||
order = 'A1'
|
||||
}, {
|
||||
type = 'bool-setting',
|
||||
name = 'PHI-EN-STEAM',
|
||||
setting_type = 'startup',
|
||||
default_value = true,
|
||||
order = 'A2'
|
||||
}, {
|
||||
type = 'bool-setting',
|
||||
name = 'PHI-EN-NUCLEAR',
|
||||
setting_type = 'startup',
|
||||
default_value = true,
|
||||
order = 'A3'
|
||||
}, {
|
||||
type = 'int-setting',
|
||||
name = 'PHI-EN-SOLAR-TIER',
|
||||
setting_type = 'startup',
|
||||
default_value = 8,
|
||||
allowed_values = {2, 3, 4, 5, 6, 7, 8},
|
||||
order = 'B1'
|
||||
allowed_values = {1, 2, 3, 4, 5, 6, 7, 8},
|
||||
order = 'A1'
|
||||
}, {
|
||||
type = 'int-setting',
|
||||
name = 'PHI-EN-STEAM-TIER',
|
||||
setting_type = 'startup',
|
||||
default_value = 5,
|
||||
allowed_values = {2, 3, 4, 5},
|
||||
order = 'B2'
|
||||
allowed_values = {1, 2, 3, 4, 5},
|
||||
order = 'A2'
|
||||
}, {
|
||||
type = 'int-setting',
|
||||
name = 'PHI-EN-NUCLEAR-TIER',
|
||||
setting_type = 'startup',
|
||||
default_value = 5,
|
||||
allowed_values = {2, 3, 4, 5},
|
||||
order = 'B3'
|
||||
allowed_values = {1, 2, 3, 4, 5},
|
||||
order = 'A3'
|
||||
}})
|
||||
Reference in New Issue
Block a user