From 585059aa32510913a60c9acd825fe2f7a5cd2c24 Mon Sep 17 00:00:00 2001 From: cannorin Date: Wed, 24 Sep 2025 20:27:57 +0900 Subject: [PATCH] kripke: add stats (2) --- apps/web/src/routes/kripke/components/template.svelte | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/apps/web/src/routes/kripke/components/template.svelte b/apps/web/src/routes/kripke/components/template.svelte index 30692b7..b5e39ab 100644 --- a/apps/web/src/routes/kripke/components/template.svelte +++ b/apps/web/src/routes/kripke/components/template.svelte @@ -5,6 +5,7 @@ import * as Dialog from "$lib/components/ui/dialog"; import { type Formula, getFrame, + isomorphic, nontrivials, tryParse, validWorlds, @@ -65,7 +66,9 @@ function evaluate() { const res: number[] = [frames.length]; for (const move of moves) { if (move.type === "guess") { - frames = frames.filter((f) => f.id !== move.frameId); + const frameId = isomorphic[move.frameId]; + if (move.correct) frames = [{ id: frameId, frame: getFrame(frameId) }]; + else frames = frames.filter((f) => f.id !== frameId); } if (move.type === "check") { if (move.valid < 0 || move.valid > 4) return undefined;