Skip to content

Commit

Permalink
Change Biofluid setting naming convention
Browse files Browse the repository at this point in the history
  • Loading branch information
Jakkowww committed Jul 12, 2024
1 parent b8952fc commit 8cfd2e6
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions locale/en/biofluid.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ priority=Priority
temperature-filter=Temperature filter

[mod-setting-name]
pal_min_fluid_reserve=Biofluid provider minimum fluid reserve
pal_min_fluid_request=Biofluid requester minimum fluid request
py-min_fluid_reserve=Biofluid provider minimum fluid reserve
py-min_fluid_request=Biofluid requester minimum fluid request

[mod-setting-description]
pal_min_fluid_reserve=Minimum fluid amount required to be present in a provider to initiate a biofluid transfer trip
pal_min_fluid_request=Minimum fluid amount required to be missing from a requester to initiate a biofluid transfer trip
py-min_fluid_reserve=Minimum fluid amount required to be present in a provider to initiate a biofluid transfer trip
py-min_fluid_request=Minimum fluid amount required to be missing from a requester to initiate a biofluid transfer trip
4 changes: 2 additions & 2 deletions scripts/biofluid/biofluid.lua
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ local function build_providers_by_contents(network_data, relavant_fluids)
local providers_by_contents = {}
network_data.providers_by_contents = providers_by_contents
local providers = network_data.providers
local min_fluid_reserve = settings.global['pal_min_fluid_reserve'].value
local min_fluid_reserve = settings.global['py-min_fluid_reserve'].value

for k, provider in pairs(providers) do
if not provider.valid then
Expand Down Expand Up @@ -573,7 +573,7 @@ end
function Biofluid.get_unfulfilled_requests()
local relavant_fluids = {}
local result = {}
local min_fluid_request = settings.global['pal_min_fluid_request'].value
local min_fluid_request = settings.global['py-min_fluid_request'].value

for unit_number, requester_data in pairs(global.biofluid_requesters) do
local requester = requester_data.entity
Expand Down
4 changes: 2 additions & 2 deletions settings.lua
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
data:extend{
{
type = 'double-setting',
name = 'pal_min_fluid_reserve',
name = 'py-min_fluid_reserve',
setting_type = 'runtime-global',
minimum_value = 1,
maximum_value = 20000,
default_value = 10000
},
{
type = 'double-setting',
name = 'pal_min_fluid_request',
name = 'py-min_fluid_request',
setting_type = 'runtime-global',
minimum_value = 1,
maximum_value = 20000,
Expand Down

0 comments on commit 8cfd2e6

Please sign in to comment.