hengmhs/smolknight

A small CLI chess puzzle game

1

stars

29

commits

Python

primary language

Jul 10, 2025

updated

README

logo

About

A quick & simple single-player CLI (command-line interface) chess puzzle game where you use a lone knight to clear the level of enemy pawns before they reach the 8th row of the board.

Each level takes less than a minute! Clear all 15 levels to complete the game.

Usage

To play, open this folder in the terminal and input the command: python3 game.py

Screenshots

Level 5: Christmas Present

s1

Level 8: False Flag

s3

Level 9: Ambush

s2

Gameplay

  1. Use your knight to stop the pawns from reaching your backline (the 8th row).
  2. After you move, all enemy pawns will move forward unless there is a pawn or knight blocking it
  3. Enemy pawns will not capture your knight.
  4. All enemy pawns in row 1 will move first, then row 2, and so on. If there is a pawn in row A1 and A2, the pawn in A1 will be blocked from moving by the pawn in A2.

Levels

  1. Lone Star
  2. Gemini
  3. Conga Line
  4. Birds of a Feather
  5. Wall Climber
  6. Christmas Present
  7. Parallel Lives
  8. Mercy
  9. False Flag
  10. Ambush
  11. Free Will
  12. Vendetta
  13. Regiment
  14. Forefathers
  15. Cascade
  16. Slice

Solver

If you would like to create your own levels, you can input the starting positions of the pawns and the knight's starting position into solver.py to check if the level is solvable. If there is no solution output, the level is not solvable.

Input the command: python3 solver.py

Requirements

You'll need to have Python 3 installed in your machine.

Acknowledgements

Logo generated with miniwi font from patorjk.com

Website

Website

Contributors

hengmhs

28 commits

kwansing14

1 commits

hengmhs/smolknight

A small CLI chess puzzle game

1

stars

29

commits

Python

primary language

Jul 10, 2025

updated

README

logo

About

A quick & simple single-player CLI (command-line interface) chess puzzle game where you use a lone knight to clear the level of enemy pawns before they reach the 8th row of the board.

Each level takes less than a minute! Clear all 15 levels to complete the game.

Usage

To play, open this folder in the terminal and input the command: python3 game.py

Screenshots

Level 5: Christmas Present

s1

Level 8: False Flag

s3

Level 9: Ambush

s2

Gameplay

  1. Use your knight to stop the pawns from reaching your backline (the 8th row).
  2. After you move, all enemy pawns will move forward unless there is a pawn or knight blocking it
  3. Enemy pawns will not capture your knight.
  4. All enemy pawns in row 1 will move first, then row 2, and so on. If there is a pawn in row A1 and A2, the pawn in A1 will be blocked from moving by the pawn in A2.

Levels

  1. Lone Star
  2. Gemini
  3. Conga Line
  4. Birds of a Feather
  5. Wall Climber
  6. Christmas Present
  7. Parallel Lives
  8. Mercy
  9. False Flag
  10. Ambush
  11. Free Will
  12. Vendetta
  13. Regiment
  14. Forefathers
  15. Cascade
  16. Slice

Solver

If you would like to create your own levels, you can input the starting positions of the pawns and the knight's starting position into solver.py to check if the level is solvable. If there is no solution output, the level is not solvable.

Input the command: python3 solver.py

Requirements

You'll need to have Python 3 installed in your machine.

Acknowledgements

Logo generated with miniwi font from patorjk.com

Website

Website

Contributors

hengmhs

28 commits

kwansing14

1 commits

Languages

Python

100.0%