From e780914ed2044be39773004bd08f3c676b5f24eb Mon Sep 17 00:00:00 2001 From: Miodec Date: Thu, 3 Mar 2022 00:16:25 +0100 Subject: [PATCH] missing replay event --- frontend/src/scripts/controllers/input-controller.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/frontend/src/scripts/controllers/input-controller.ts b/frontend/src/scripts/controllers/input-controller.ts index c68efbac3..12262856b 100644 --- a/frontend/src/scripts/controllers/input-controller.ts +++ b/frontend/src/scripts/controllers/input-controller.ts @@ -466,6 +466,11 @@ function handleChar(char: string, charIndex: number): void { TestInput.updateLastKeypress(); TestInput.pushKeypressWord(TestWords.words.currentIndex); + Replay.addReplayEvent( + thisCharCorrect ? "correctLetter" : "incorrectLetter", + char + ); + if (!thisCharCorrect && Config.difficulty == "master") { TestInput.input.pushHistory(); TestInput.corrected.pushHistory();