ennemi's vessels are going toward the player fleet instantly, they should only when they arrive at a given detection range #69

Closed
opened 2026-08-16 11:41:03 +00:00 by metaheavens · 1 comment
Owner
No description provided.
Author
Owner

Implemented and pushed in 1de66c6.

Gave pursuit and standoff enemies a finite detection_range (chaser/pursuit: 850, standoff/sniper: 1200) instead of instantly and omnisciently beelining for the fleet the moment they spawn regardless of distance - they now sit idle until the fleet enters range, then close in/engage as before. Artillery enemies already had a usable fire_range for this purpose and just needed their existing drift gated by it.

The mothership is a deliberate exception - it shares EnemyPursuitComponent.gd but needed to keep tracking from anywhere on the map, so it gets its own scene variant, EnemyPursuitComponentMothership.tscn (detection_range = 1000000.0), following the same per-definition-override pattern already established by EnemySpawnerComponentChaser/Artillery.

Tests: tests/test_enemy_detection_range.gd (bash tests/run_tests.sh enemy_detection_range) - chaser idle beyond range then closes in, sniper idle beyond range, mothership closes in from 5000 units out.

Implemented and pushed in `1de66c6`. Gave pursuit and standoff enemies a finite `detection_range` (chaser/pursuit: 850, standoff/sniper: 1200) instead of instantly and omnisciently beelining for the fleet the moment they spawn regardless of distance - they now sit idle until the fleet enters range, then close in/engage as before. Artillery enemies already had a usable `fire_range` for this purpose and just needed their existing drift gated by it. The mothership is a deliberate exception - it shares `EnemyPursuitComponent.gd` but needed to keep tracking from anywhere on the map, so it gets its own scene variant, `EnemyPursuitComponentMothership.tscn` (`detection_range = 1000000.0`), following the same per-definition-override pattern already established by `EnemySpawnerComponentChaser`/`Artillery`. Tests: `tests/test_enemy_detection_range.gd` (`bash tests/run_tests.sh enemy_detection_range`) - chaser idle beyond range then closes in, sniper idle beyond range, mothership closes in from 5000 units out.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
metaheavens/spaceship#69
No description provided.