From 00e17d1f283c6b0c2a32ef76bd1ad0e17580342b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20F=C3=B6rtsch?= Date: Thu, 12 Mar 2026 22:12:41 +0100 Subject: [PATCH] add actual results schema, prediction points to leaderboard and game state Co-Authored-By: Claude Opus 4.6 --- packages/shared/src/game-types.ts | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/packages/shared/src/game-types.ts b/packages/shared/src/game-types.ts index aabf9a4..0474264 100644 --- a/packages/shared/src/game-types.ts +++ b/packages/shared/src/game-types.ts @@ -37,6 +37,17 @@ export const predictionSchema = z.object({ export type Prediction = z.infer +// ─── Actual Results ───────────────────────────────────────────────── + +export const actualResultsSchema = z.object({ + winner: z.string(), + second: z.string(), + third: z.string(), + last: z.string(), +}) + +export type ActualResults = z.infer + // ─── Jury Voting ──────────────────────────────────────────────────── export const juryRoundSchema = z.object({ @@ -83,6 +94,7 @@ export const leaderboardEntrySchema = z.object({ displayName: z.string(), juryPoints: z.number(), bingoPoints: z.number(), + predictionPoints: z.number(), totalPoints: z.number(), }) @@ -105,6 +117,7 @@ export const gameStateSchema = z.object({ playerId: z.string(), displayName: z.string(), })), + actualResults: actualResultsSchema.nullable(), // Leaderboard leaderboard: z.array(leaderboardEntrySchema), })