Resource Restorer

This is the place to request new mods or give ideas about what could be done.
Taoh
Burner Inserter
Burner Inserter
Posts: 9
Joined: Sun Jun 28, 2015 12:23 am
Contact:

Resource Restorer

Post by Taoh »

I hope this is the right spot for this request, and it is somewhat clear what I am requesting, else please let me know, and I will try and clarify it.

The idea behind this mod is to restore resources over time as you exploit them, changing the locations of the operation, but overall keep an area supplied. Could require a survey building to activate this. This might not be the most logic thing that resources appear out of thin air, then again an explanation could be that by surveying deeper pockets of resources are found. Logic aside, the point is to allow you to make due with lower amounts of materials, still have to move around the mining camps/train stations.

How this could work.

You decide a max "restock too" amount of minerals you want per sector (reason for sectors is to allow calculations only on discovered land, allow local clusters and faster restore to fully depleted sectors)
You decide the duration between ticks (game daily would be my suggestion for a default).
You decide a restock %, my suggestion would be to keep this relative low like 2-5%
A sector might be a 100x100 grid (4x 50x50), or even larger.

The map is divided into sectors that overlap. If the numpad would be a part of the map, then 5 would be part of the sectors (7,8,4,5), (8,9,5,6), (4,5,1,2), (5,6,2,3), this means each area are part of 4 sectors.

At each tick, each sector is evaluated (possible at random order, or by comparing to old values), and the difference in the resource between the restock too, and current are found, 1/4th of the restock % is added to the sector depending on placement rules. (1/4th as each tile is part of 4 sectors).

The restock logic could be:
*Never restock to higher amounts of materials then a certain value in a single stack.
*Mostly restock connected to materials already in the area or increase current deposit tiles, this is to make deposits more likely to form in clusters.
*Only create new deposits if there are less then a certain amount in the sector, as the deposits in a sector shrinks the likelihood of a new deposit increases.
*Possible provide penalties to restocking/create new deposits near current buildings (reduces the chance of deposits being found under the main bus/currently drilled areas).

This should over time make you able to clear out zones, wait for new deposits to recover, and then clean it out again, avoiding the need for miles and miles of track, while still keeping the mining management and efficient recovery a part of the game.
dalsio
Burner Inserter
Burner Inserter
Posts: 10
Joined: Sun Jun 21, 2015 9:56 pm
Contact:

Re: Resource Restorer

Post by dalsio »

Interesting idea. The basics, that is replenishing resources, is possible. One thing that isn't possible, or at least isn't easy, is once a resource node has been depleted completely, there's no real way to keep track of it once the game ends since when they are depleted the entity itself is removed from the game, and any reference to it would have to be kept in the script. Once the game is exited or another save loaded, that script ends and any memory of that node vanishes. One might be able to save the node's data and location in a file and reference that file as needed, but I don't believe there is a large enough support for this feature to store and read data easily to be transferred from one save file to another.

I guess I could write a script that creates an invisible dummy entity with no collision whenever a resource node is depleted that acts as a "depleted node". Then, it could be replaced at the appropriate time.

More easily, however, would have the resource regeneration based around an already existing item, such as an "ore replenisher" where you place it down, give it power, and every so often in a specific area resources are gathered together and slowly generated. Alternatively, the script could find any already existing nodes and simply generate and replenish nodes on the edges of the areas of resources, kind of like a "growth" effect. Thus, as long as you don't deplete the "pool" of nodes completely (essentially leave a "seed" node), it will slowly grow more ore over time.

I'll add it to my list of, "things to maybe make in the future." The easy method probably sooner, and the complex method maybe a lower priority.
Post Reply

Return to “Ideas and Requests For Mods”