Skip to content

Instantly share code, notes, and snippets.

@1UPNuke
Last active October 21, 2021 19:58
Show Gist options
  • Select an option

  • Save 1UPNuke/6484b5f07b8faf2819871d4f336467c2 to your computer and use it in GitHub Desktop.

Select an option

Save 1UPNuke/6484b5f07b8faf2819871d4f336467c2 to your computer and use it in GitHub Desktop.
Ridiculous chess notation based on base64.

♟️ Chess64 ♟️

This is an esoteric chess move notation using a total of 64 characters, thus being Base64 compatible.

If saved in a file, it should be converted from base64 into binary with the header CHESS64 in ASCII and the file extension .chess64.

Table of contents

  1. Board
    1. Division
    2. Table
  2. Notation
    1. Special cases
      1. Promotion
      2. Castling
      3. Resign/Draw
      4. En passant
  3. Example

Board

As a chess board is made up of 64 squares, it's notated by characters used in Base64 encoding.

Division

White's half of the board uses uppercase letters, odd numbers, and a plus.

Black's half of the board uses lowercase letters, even numbers, and a slash.

Both sides are rougly mirrored, with the letters changing case, numbers having a difference of 1, and special characters switching.

Table

a b c d e f g h
i j k l m n o p
q r s t u v w x
y z 0 2 4 6 8 /
Y Z 1 3 5 7 9 +
Q R S T U V W X
I J K L M N O P
A B C D E F G H

Notation

Moves are notated sequentially alternating between white and black, as you would in normal chess notation. With both the starting and destination square given (for example M5m4GVbs)

Spaces or other forms of whitespace should not be used to maintain base64 compatibility.

Special cases

As not all chess moves can be notated via a simple movement from square to square, special cases exist.

Promotion

In the case of pawn promotion, a special format is used:

  • The movement of the pawn is notated first as normal.

  • The piece is chosen by using its character in algebraic notation twice (illegal move as piece would stand still)

    • RR or rr = Rook
    • NN or nn = Knight
    • BB or bb = Bishop
    • QQ or qq = Queen
  • Notation then resumes as normal.

Example: nfQQ

Castling

Even though castling wouldn't require special notation, as it requires movement that is normally illegal for the king, you can use the following notation of the rooks "standing still" to imply castling:

  • AA or aa = Queen's side castling
  • HH or hh = King's side castling

Resign/Draw

A resign is noted by the king algebraically twice as KK or kk, implying knocking it over (illegal move as piece would stand still).

A draw is noted by doing the same but with the letter D, as in DD or dd. This is because D is short for "Draw".

En passant

En passant does not use a special notation, the pawn's movement is noted as normal.

Example

1. e4 e5 2. Nf3 Nc6 3. Bc4 Bd6 4. O-O b6 5. Nxe5 Bxe5 6. Qh5 Nf6 7. Qxf7# 1-0

Would become

M5m4GVbsF1ftHHV4t4D/gv/n
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment