null check on warship target unit

This commit is contained in:
Evan
2025-03-07 10:25:31 -08:00
parent 673a7a400c
commit 25224ed749
+1 -1
View File
@@ -249,7 +249,7 @@ export class UnitLayer implements Layer {
const targetOwner = this.game
.units()
.find((u) => u.id() == unit.targetId())
.owner();
?.owner();
if (targetOwner == this.myPlayer) {
outerColor = colord({ r: 200, b: 0, g: 0 });
}