kokopu
Version:
A JavaScript/TypeScript library implementing the chess game rules and providing tools to read/write the standard chess file formats.
34 lines (33 loc) • 1.44 kB
Plain Text
Event = {Game with tags}
[] -+<LONG
[] (1w) e4 (
[] (1b) h5 (
|
[] +---+ [key = {value}] {More usual is}
[] | (1b) c5 (
|
[] (2w) d4 (
[] (2b) a5 (
[] (3w) c4 (
[] (3b) g5 (
[] (4w) f4 (
[] (4b) b5 (
+---+---+---+---+---+---+---+---+
| r | n | b | q | k | b | n | r |
+---+---+---+---+---+---+---+---+
| | | p | p | p | p | | |
+---+---+---+---+---+---+---+---+
| | | | | | | | |
+---+---+---+---+---+---+---+---+
| p | p | | | | | p | p |
+---+---+---+---+---+---+---+---+
| | | P | P | P | P | | |
+---+---+---+---+---+---+---+---+
| | | | | | | | |
+---+---+---+---+---+---+---+---+
| P | P | | | | | P | P |
+---+---+---+---+---+---+---+---+
| R | N | B | Q | K | B | N | R |
+---+---+---+---+---+---+---+---+
w KQkq -
{Line}{8 plies}