container/engine
coyotte508 e36715fedc engine: reject turn buffers that continue past a turn boundary
The whole-turn buffer is replayed from the committed state; committing is
what grants the mover their per-turn time increment. In the degenerate
all-others-dropped case a buffer like [..., Pass, ...more] is a sequence of
individually legal moves spanning several turns — it would commit them all
for a single increment. Throw as soon as a committed move is followed by
more buffer elements.

Also log an error when moveAI's 500-iteration force-commit safety net
fires, so a would-be livelock is visible in server logs instead of being
silently masked.

Tests: malformed buffer rejection (nothing half-applied leaks) and
multi-turn buffer rejection.
2026-08-16 21:26:05 +00:00
..
.vscode Add continuous integration 2021-07-04 00:06:50 +02:00
src engine: reject turn buffers that continue past a turn boundary 2026-08-16 21:26:05 +00:00
.eslintrc.js Use lodash to simplify game generation 2021-07-04 02:36:34 +02:00
.gitignore Add continuous integration 2021-07-04 00:06:50 +02:00
.travis.yml Add continuous integration 2021-07-04 00:06:50 +02:00
index.ts ✨ (engine) Export moveAI for bot players 2026-08-12 21:40:04 +02:00
LICENSE Move engine code into engine subfolder 2021-07-03 21:23:00 +02:00
package.json engine: replace destructive undo with tentative-turn model 2026-08-16 20:55:44 +00:00
pnpm-lock.yaml Add continuous integration 2021-07-04 00:06:50 +02:00
README.md Mono-repo configuration 2021-07-03 21:39:13 +02:00
tsconfig.json ✅ (engine) Add full game sample 2021-10-14 22:07:27 +02:00
wrapper.ts engine: reject turn buffers that continue past a turn boundary 2026-08-16 21:26:05 +00:00

container-engine

Typescript engine for Container.

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