UK & Ireland's island jump needs an empty city, so a player locked on one island tops out at its cities (14 and 12 on a 4-region board). If nobody crosses before the other island fills, no one can ever reach the end count and the game never ended. Two seeded bot games showed how master escaped: after ~105 rounds a player saved $9999 and bought a city priced 9999, the engine's "impossible" marker (occupied, or across the sea). New games store options.stallEnds. For them, the game ends after a Step 3 Building phase in which no active player could ever build again (whatever their money), scored as usual; and a 9999 price is never affordable. Older games have no stamp (reconstructionOptions forces it off), so they play and replay exactly as before. Build pricing moves out of availableMoves into buildOptions() so the money-filtered moves and noPlayerCanBuild() share every map rule. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| .vscode | ||
| src | ||
| .eslintignore | ||
| .eslintrc.js | ||
| .gitignore | ||
| .pnpm-debug.log | ||
| .travis.yml | ||
| index.ts | ||
| LICENSE | ||
| package-lock.json | ||
| package.json | ||
| pnpm-lock.yaml | ||
| README.md | ||
| tsconfig.json | ||
| wrapper.ts | ||
powergrid-engine
Typescript engine for Power Grid.
Setup
Requirements
Recent version of node / pnpm.
Dependencies
In the project's folder:
pnpm
Build
To compile Typescript into javascript:
pnpm build
Test
pnpm test