#97g: garrison vessels patrol and defend their outpost #105
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Subticket of #97, depends on #97f.
"When a vessel is assigned to an outpost, it navigates around the outpost by
itself, attacking nearby ennemies if any are detected."
afterwards, rather than being pulled across the map.
against
max_fleet_size(), and does not move when the player flies away.Done in
bd0cc84.A garrisoned vessel circles its post, engages what comes into range, and goes
back to circling. It steers by writing move_target and lets Ship's own steering
fly it, so it accelerates and banks exactly like a vessel in the formation, and
it is not in Fleet.ships - no formation, no fleet slot consumed, and it stays
put when you fly away.
The leash is the load-bearing part. Enemies are judged from the POST rather than
from the vessel, so a garrison that has drifted out to its leash cannot see
further still and be walked away from its outpost one enemy at a time; an
engagement is clamped to a circle around the post rather than to a straight
line, so it still manoeuvres while pinned.
Two things worth recording:
random one makes the first waypoint a point on the far side of the circle, and
the vessel flies straight across the middle - through the outpost it is
guarding. That was a real bug the test caught.
Fleet.ships, or an enemy would ignore the guns shooting at it and a garrison
could hold a position without ever being fought back.