Commit 1050fd15 authored by Mahmoud Aglan's avatar Mahmoud Aglan

fix: getPipCount used non-existent VARIANTS.standard key

The VARIANTS object has keys 'sheshbesh', 'mahbousa', 'thirtyone' but
getPipCount referenced 'standard' which is undefined, causing
'Cannot read properties of undefined (reading normPos)' and preventing
the entire board from rendering.
Co-Authored-By: 's avatarClaude Opus 4.6 <noreply@anthropic.com>
parent c5374e12
...@@ -264,7 +264,7 @@ export function getGameScore(state, winner, rule) { ...@@ -264,7 +264,7 @@ export function getGameScore(state, winner, rule) {
} }
export function getPipCount(state, type) { export function getPipCount(state, type) {
const rule = VARIANTS.standard; const rule = VARIANTS.sheshbesh;
let pips = 0; let pips = 0;
for (let i = 0; i < 24; i++) { for (let i = 0; i < 24; i++) {
const count = countAtPos(state, i, type); const count = countAtPos(state, i, type);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment