From 07a83e6bd1f35ae13944859b84af9f9daa634ebc Mon Sep 17 00:00:00 2001 From: Milos Date: Tue, 29 Oct 2024 19:40:46 +0100 Subject: [PATCH] fix: creature vignette next turn status text --- src/ui/queue.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ui/queue.ts b/src/ui/queue.ts index ea2bd7aea..50cfed6c2 100644 --- a/src/ui/queue.ts +++ b/src/ui/queue.ts @@ -86,7 +86,7 @@ export class Queue { const is1stCreature = utils.trueIfFirstElseFalse(); const newCreatureVCurr = (c: Creature) => - new CreatureVignette(c, turnNum, eventHandlers, is1stCreature()); + new CreatureVignette(c, turnNum, eventHandlers, is1stCreature(), true); const undelayedVsCurr = undelayedCsCurr.map(newCreatureVCurr); const delayMarkerVCurr = hasDelayedCurr ? [new DelayMarkerVignette(turnNum, eventHandlers)] @@ -96,7 +96,7 @@ export class Queue { const turnEndMarkerV = [new TurnEndMarkerVignette(turnNum, eventHandlers)]; const newCreatureVNext = (c: Creature) => - new CreatureVignette(c, turnNum + 1, eventHandlers, is1stCreature()); + new CreatureVignette(c, turnNum + 1, eventHandlers, is1stCreature(), false); const undelayedVsNext = undelayedCsNext.map(newCreatureVNext); const delayMarkerVNext = hasDelayedNext ? [new DelayMarkerVignette(turnNum + 1, eventHandlers)] @@ -431,7 +431,7 @@ class CreatureVignette extends Vignette { this.el.style.zIndex = this.creature.temp ? '1000' : this.queuePosition + 1 + ''; - const stats = this.creature.fatigueText; + const stats = this.turnNumberIsCurrentTurn ? this.creature.fatigueText : 'Queued'; const statsClasses = ['stats', utils.toClassName(stats)].join(' '); const statsEl = this.el.querySelector('div.stats'); statsEl.className = statsClasses;