Skip to content

Latest commit

 

History

History
60 lines (53 loc) · 2.93 KB

README.md

File metadata and controls

60 lines (53 loc) · 2.93 KB

Conway's Game of Chess

Chess, but each square also follows the rules of Conway's Game of Life.

  • Only your own pieces count as neighbours when deciding births/deaths.
  • For births, an empty square must have 3 neighbours for 2 consecutive turns.
  • For deaths, a piece must have <2 or >3 neighbours for 3 consecutive turns.

This is a simple proof of concept I made with python and curses.

You can play with a friend locally or over a socket connection.

See instructions with python3 conway_chess.py --help

Controls:

  • Arrow keys to move the cursor
  • Enter or space to select and move a piece
  • u or backspace to undo a move
  • r to redo a move
  • q or escape to quit
  • s to perform a move with stockfish if installed (useless since it has no knowledge of this variant)
  • any other key to unselect a currently selected piece

Legend:

                    White birth queue ┐
White: P R P N P B P Q P B P N P R  <─┘
┌──────────────────────────────────────┐
│ # <─ White birth COUNTER on empty  w │
│      squares, born from queue on   ^ │
│      next turn after reaching 2    │ │
│                                    │ │
│   INDICATOR that white has exactly ┘ │
│   3 nearby pieces, birth counter     │
│   will increment at the start of the │
│   next turn, black birth counter and │
│   indicator are below and separate   │
│                                      │
│ #               ♔ <─ Piece symbol  o │
│ ^                                  ^ │
│ └ Death COUNTER on occupied        │ │
│   squares, dies after reaching 3   │ │
│                                    │ │
│   INDICATOR that the piece has > 3 ┘ │
│   nearby pieces (overpopulation),    │
│   or < 2 nearby pieces               │
│   (underpopulation) and will die     │
│                                      │
│ # <─ Black COUNTER & INDICATOR ──> l │
└──────────────────────────────────────┘
The INDICATORs are updated immediately when the conditions are met.
The COUNTERs are incremented only at the start of the respective player's turn.
Births and deaths also only occur at the start of the respective player's turn.
If the conditions for a birth or death counter are no longer met, (as shown by the indicators), the counter resets.
Opponent pieces are not counted as nearby pieces for the birth/death population criteria.
On birth, pieces are taken from the birth queue (circular) and placed on the board in order of rank then file.
Placement starts from rank 1 for white and rank 8 for black, with both filling the board from left to right.
The game ends when the king is captured or perishes due to over/underpopulation.