mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-06-21 15:00:43 +00:00
null check on warship target unit
This commit is contained in:
@@ -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 });
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user