diff --git a/TODO b/TODO index 19f7ef25d2..54a5293746 100644 --- a/TODO +++ b/TODO @@ -6,9 +6,9 @@ shootouts - show attempt number in play-by-play - scoring summary - "1 run scores" -> "Shootout" - - test if fast forward to end of inning/side doesn't stop before shootout - hockey - confirm for all sports + - check what fast-forward options are shown during shootout - no injuries during shootout - if still tied, keep going one at a time - make sure it's not all 0, all sports should have some min prob of success diff --git a/src/ui/components/BoxScoreWrapper.tsx b/src/ui/components/BoxScoreWrapper.tsx index cdc96f6a2c..b1944fdf70 100644 --- a/src/ui/components/BoxScoreWrapper.tsx +++ b/src/ui/components/BoxScoreWrapper.tsx @@ -164,16 +164,18 @@ export const HeadlineScore = ({ {boxScore.gameOver ? "Final score" - : boxScore.elamTarget !== undefined - ? `Elam Ending target: ${boxScore.elamTarget} points` - : isSport("baseball") - ? `${ - boxScore.teams[0].ptsQtrs.length === - boxScore.teams[1].ptsQtrs.length - ? "Bottom" - : "Top" - } of the ${boxScore.quarter}` - : `${boxScore.quarter}, ${boxScore.time} remaining`} + : boxScore.shootout + ? "Shootout" + : boxScore.elamTarget !== undefined + ? `Elam Ending target: ${boxScore.elamTarget} points` + : isSport("baseball") + ? `${ + boxScore.teams[0].ptsQtrs.length === + boxScore.teams[1].ptsQtrs.length + ? "Bottom" + : "Top" + } of the ${boxScore.quarter}` + : `${boxScore.quarter}, ${boxScore.time} remaining`} {boxScore.gameOver diff --git a/src/ui/views/LiveGame.tsx b/src/ui/views/LiveGame.tsx index 8223db8f97..ef0cc36034 100644 --- a/src/ui/views/LiveGame.tsx +++ b/src/ui/views/LiveGame.tsx @@ -533,7 +533,11 @@ export const LiveGame = (props: View<"liveGame">) => { const playSeconds = (cutoff: number) => { let seconds = 0; let numPlays = 0; - while (seconds < cutoff && !boxScore.current.gameOver) { + while ( + seconds < cutoff && + !boxScore.current.gameOver && + !boxScore.current.shootout + ) { const elapsedSeconds = processToNextPause(true); numPlays += 1; if (elapsedSeconds > 0) { @@ -583,7 +587,11 @@ export const LiveGame = (props: View<"liveGame">) => { boxScore.current.teams[0].pts + boxScore.current.teams[1].pts; let currentPts = initialPts; let numPlays = 0; - while (initialPts === currentPts && !boxScore.current.gameOver) { + while ( + initialPts === currentPts && + !boxScore.current.gameOver && + !boxScore.current.shootout + ) { processToNextPause(true); currentPts = boxScore.current.teams[0].pts + boxScore.current.teams[1].pts; @@ -738,7 +746,10 @@ export const LiveGame = (props: View<"liveGame">) => { let numPlays = 0; const numSidesSoFar = getNumSidesSoFar(); - while (!boxScore.current.gameOver) { + while ( + !boxScore.current.gameOver && + !boxScore.current.shootout + ) { processToNextPause(true); numPlays += 1; @@ -757,7 +768,10 @@ export const LiveGame = (props: View<"liveGame">) => { let numPlays = 0; const numSidesSoFar = getNumSidesSoFar(); - while (!boxScore.current.gameOver) { + while ( + !boxScore.current.gameOver && + !boxScore.current.shootout + ) { processToNextPause(true); numPlays += 1;