Spidertron Patrols


Send spidertrons on patrols and automatically load and unload them using docks. Adds mid-game spiderling to allow the new features to be used sooner. Replacement for Spidertron Waypoints. Simpler alternative to AAI Programmable Vehicles. Allows creating patrols for Lex's Aircraft.

Content
5 months ago
1.1
35.3K
Logistics Combat

i Always use the pathfinding

1 year, 4 months ago

Hi,
How about spidertrons always use the pathfinding (from Spidertron extensions (Alt+click)). It would make it way easier to go from dock to dock, to never worry about water anymore.

Thanks for this great mod

1 year, 4 months ago
(updated 1 year, 4 months ago)

Thanks for the suggestion, I’ve considered this before but not done it yet for a couple of reasons:

  1. It is quite fiddly to implement anything with the pathfinder, because I have to request the path, but I don’t get the result returned until a later time (around a second later). Not a reason not to do it, just a reason to put it off :D

  2. When should the paths be calculated?
    If it is ‘when the patrol is setup’, then the paths may become incorrect later on if water is created, space scaffolding removes (SE), large buildings placed in the way (these aren’t currently accounted for in Spidertron Enhancements pathfinding, but will be soon!), etc.
    If it is ‘every time it sets off to a new waypoint’ then I have performance concerns with so many calls to the pathfinder, may cause UPS issues if many are in use simultaneously.

I’m inclined to go for the second option, with a checkbox in the patrol gui to enable the pathfinding per-spidertron. Thoughts?

1 year, 4 months ago

Thanks for your quick feedback. Honestly, I have no coding backgrund so i can't comment from that perspective.... However, the second one seems the best, and how many spidertrons will there be...

1 year, 2 months ago
(updated 1 year, 2 months ago)

Hi,
First: Thank you so much for maintaining this mod - it opens so many ways to solve problems I didn't know I had :-)

Second: As to your question "thoughts": I was thinking about how cool pathfinding would be, and understanding potential performance impact, how about it is optional such that: Only when setting a petrol point with the petrol remote one could alt-click with for that specific waypoint to use pathfinding, while default is "no" (which would existing petrols set up unchanged)

  • in that case calc the route only once or in one of the following cases:
  • prev. waypoint changes (e.g. moving / deleting waypoints)
  • switched from "manual" to "auto" to reach next waypoint
  • spider becomes stuck for more than X time (if that can be checked)
  • if possible add the option to switch between "straight" and "pathfinding" (checkbox?) in the waypoint setting, and if toggled, also recalc once.

In that case the player can always decide performance vs. "need pathfinding for this part because I overlooked a huge lake and would need to set up 10 more waypoints to navigate around it or build a bridge" :-)

Thanks for your kind consideration!

edit: typo

1 year, 2 months ago

Thanks for the suggestions! Your method does seem pretty thought-out.
It all sounds possible, but it is very complex to program because the pathfinding happens over many ticks, so everything has to be stored and retrieved later, during which time anything could have happened (e.g. spidertron deletion, a new command issued, etc, etc).

spider becomes stuck for more than X time (if that can be checked)

Also theoretically possible, but very complex as it happens over multiple ticks.

if possible add the option to switch between "straight" and "pathfinding" (checkbox?) in the waypoint setting, and if toggled, also recalc once.

I don't think there's space in the GUI for this, it is too wide as-is (especially with today's v2.4.0 which adds another button!). I'm not saying that I won't implement it, but it is still low priority, I'm afraid.

It has also been suggested that the spidertron logistics is too overpowered already, and perhaps the 'manual-ness' of the setup helps keep it from overuse :P

1 year, 2 months ago

Thanks for taking my suggestions under consideration - looking forward what might happen next :-)

New response