diff --git a/src/client/graphics/layers/GhostStructureManager.ts b/src/client/graphics/layers/GhostStructureManager.ts index 8851a390f..b40e7c5b9 100644 --- a/src/client/graphics/layers/GhostStructureManager.ts +++ b/src/client/graphics/layers/GhostStructureManager.ts @@ -174,10 +174,14 @@ export class GhostStructureManager { } } + const currentGhost = this.ghostUnit; this.game .myPlayer() ?.actions(tileRef) .then((actions) => { + // Check if ghost is still valid and hasn't changed + if (!this.ghostUnit || this.ghostUnit !== currentGhost) return; + // Clear previous highlights/filters this.onHighlightUpgrade(null); if (this.ghostUnit?.container) {