[Rseding91] 2.0.12 minimum value not respected for a resource that is made infinite like in pre 2.0
Posted: Mon Oct 28, 2024 7:00 pm
minimum resource value not respected for a resource that is made infinite like in pre 2.0 and infinite_depletion_amount doesn't do anything.
I want to make all ores infinite but so that the decrease to a minimum percentage value like 10%. The problem is that the following code no longer works properly for other planets:
for k, v in pairs(data.raw.resource) do
data.raw.resource[k].infinite = true
data.raw.resource[k].minimum = 10
data.raw.resource[k].normal = 100
end
how can I make all resources on all planets infinite but degrade to their minimum value and stay there? Ie ores, scrap etc.
I want all ores, scrap etc to start at say 100% yield and decrade to say 10%, or 20% yield (whatever I set it to) and then stay there permanently and never go lower. The issue seems to be that setting the starting yield by setting the following:
resource.initial_amount
resource.amount
will result in the yield starting at 100% but then never decrease to the 20%. If you don't set the above then each miner will produce like 70 ore per second.
Thanks
I want to make all ores infinite but so that the decrease to a minimum percentage value like 10%. The problem is that the following code no longer works properly for other planets:
for k, v in pairs(data.raw.resource) do
data.raw.resource[k].infinite = true
data.raw.resource[k].minimum = 10
data.raw.resource[k].normal = 100
end
how can I make all resources on all planets infinite but degrade to their minimum value and stay there? Ie ores, scrap etc.
I want all ores, scrap etc to start at say 100% yield and decrade to say 10%, or 20% yield (whatever I set it to) and then stay there permanently and never go lower. The issue seems to be that setting the starting yield by setting the following:
resource.initial_amount
resource.amount
will result in the yield starting at 100% but then never decrease to the 20%. If you don't set the above then each miner will produce like 70 ore per second.
Thanks