mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-07-03 19:40:49 +00:00
feat: WarShips red color outside if target current player
Hard to know when warship captures your trade so if they target one of your trade or war ship they are highlighted in red. Known limitation: doesn't work well if the WarShip is already in red (player's color)
This commit is contained in:
@@ -96,6 +96,7 @@ export class WarshipExecution implements Execution {
|
||||
return distSortUnit(this.mg, this.warship)(a, b);
|
||||
})[0] ?? null;
|
||||
|
||||
this.warship.setTarget(this.target);
|
||||
if (this.target == null || this.target.type() != UnitType.TradeShip) {
|
||||
// Patrol unless we are hunting down a tradeship
|
||||
const result = this.pathfinder.nextTile(
|
||||
|
||||
Reference in New Issue
Block a user