From cb9a54810deace0ef199cd4c49251425f0b13bd2 Mon Sep 17 00:00:00 2001 From: Miodec Date: Thu, 6 Apr 2023 02:00:48 +0200 Subject: [PATCH] last key to end is 0 if in zen mode --- frontend/src/ts/test/test-logic.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/frontend/src/ts/test/test-logic.ts b/frontend/src/ts/test/test-logic.ts index a99781aba..f4aa96748 100644 --- a/frontend/src/ts/test/test-logic.ts +++ b/frontend/src/ts/test/test-logic.ts @@ -1382,9 +1382,10 @@ function buildCompletedEvent(difficultyFailed: boolean): CompletedEvent { keySpacing: TestInput.keypressTimings.spacing.array, keyDuration: TestInput.keypressTimings.duration.array, keyOverlap: Misc.roundTo2(TestInput.keyOverlap.total), - lastKeyToEnd: Misc.roundTo2( - TestStats.end - TestInput.keypressTimings.spacing.last - ), + lastKeyToEnd: + Config.mode === "zen" + ? 0 + : Misc.roundTo2(TestStats.end - TestInput.keypressTimings.spacing.last), startToFirstKey: Misc.roundTo2( TestInput.keypressTimings.spacing.first - TestStats.start ),