Page 1 of 1

[2.0.28] Automatic artillery train

Posted: Sun Dec 22, 2024 4:37 pm
by Hares
Sharing my design of automated patrolling artillery train.
Train goes from one artillery position to another until it runs out of ammo, prioritizing train stops it has not visited for longest time.
Blueprint
12-22-2024, 19-06-38.png
12-22-2024, 19-06-38.png (2.59 MiB) Viewed 168 times


How it works?
Pretty damn simple, by the way.
Due to 2.0 train system engine limitation (see: 118475: [2.0.12] Train does not move between stops with same name (MR)), train schedule is required to have stops with different names to advance in the schedule, that's why schedule (and each artillery position) contains "Approach" and "Fire Position" stops tight together. Each "Fire Position" stop has a timer which resets when the train is parked, and increases both stops priority over time (default configuration: +1 priority per minute -- see configuration section below for details).

Train waits on the firing position until it runs out of ammo, or until certain inactivity period has passed. After that, it decides to either go home or visit another artillery position. It will go home if:
  • It is low on fuel (see p.3 in Usage)
  • It is completely out of ammo
  • No artillery position train stops are available
Otherwise, it will visit another artillery position based on priority which represents time since artillery train visited it. "Approach" and "Fire Position" share train limits (==1) and priority, but only the latter will reset the memory cell.

Technically, this system can support multiple artillery trains, but the system was never tested for that. That will require additional adjustments to the rearming train stop including but not limited: adding extra reload stations, adding enabled conditions, setting dynamic limits, and/or adding depotting/waiting bays for it.

Usage
  1. Deploy train & train reload station (they are on the same blueprint). Train comes with schedule & reload interrupt.
  2. Make artillery as long as your rail system can handle (I personally use 1-4-1 train stops, but this system would work with any design). Add inserters to load artillery shells.
  3. Adjust refueling logic to match your rail system. Currently, the train is configured to refuel at specific refueling train stop, but you can refuel it on the hub and merge two interrupt conditions.
  4. Deploy artillery position train stops in the safest spots of your outposts or perimeters as these train stops come with no defense.
  5. Let the fun begin!
Configuration
12-22-2024, 19-24-08.png
12-22-2024, 19-24-08.png (381.2 KiB) Viewed 168 times
This constant combinator uses logistical groups to allow bulk edits of configuration within the entire savefile, and comes with two options:
  • P signal. Defines time interval (in ticks) after which priority of train stop increases.

    Code: Select all

    Priority = <Ticks since train left station> รท P
  • T signal. Any non-zero signal here will reset the system -- all priorities will be reset; and artillery train will finish its route and might after that return home.

Re: [2.0.28] Automatic artillery train

Posted: Sun Dec 29, 2024 4:42 pm
by Berndie
I use a closed ring of artillery outposts with overlapping range which are defended. First i don't want pollution strengthen the red ones, second i don't want my factories/mining outposts to draw their attention. Another experience is, that a few rounds now and then "invites" only a few unwanted guests at a time. So defense is easy.

As in SA cannons are more expensive your way of transporting them where they are needed is very convenient. But the best in my eyes is your idea of increasing the priority by time - a perfect solution as the enemies need only attention once in a while. Not too much to create problems at the cannons firing places, not too little to allow them to settle/walk "through" the protected area.

I hope this also helps with the enormous amount of rounds needed when firing range increases from time to time, so that at none of the outpost has too long periods without ammunition. Without this distribution the artillery outposts need a lot of ammunition at the same moment so all are served (repeatedly) within time.

So i will need a logic to discharge only a small number of rounds at every outpost ...