Standard Chess
Designed by | MasterWoodie |
---|---|
Appeared in | 2023 |
Memory system | tape |
Computational class | Unknown |
Reference implementation | MasterWoodie Homepage |
File extension(s) | .stdchess |
Standard Chess is a programming language, that is designed to look like a chess game. It was created by MasterWoodie in 2023
Moves
Standard Chess uses Chess Notation:
Piece | Notation |
---|---|
King | K
|
Queen | Q
|
Rook | R
|
Bishop | B
|
Knight | N
|
Pawn | Nothing |
The position is defined by a letter (a-h) and a number (0-8)
Special Moves:
Move | Notation |
---|---|
Capture | x in front of the position
|
Check | + behind the position
|
Castle | 0-0 or 0-0-0
|
Pawn Promotion | =<Piece> behind the move
|
Mate | #
|
Draw | 1/2
|
Structure
In a Standard Chess Program only chess moves are allowed.
The language operates on a tape, where each cell can hold a value between 0 and 255
Important: Every Standard Chess Program needs a result (Mate or Draw)
The commands of the program are based on the piece:
Piece | Description |
---|---|
King | Flow control: a = check? or take?, j = currentValue is not 0?, dif = positionLetter - positionDigit, amount= 1 |
Queen | Random Stuff: a = check? or take?, dif = positionLetter - positionDigit |
Rook | Tape Movement: a = check? or take?, dif = positionLetter - positionDigit, amount = 1 |
Bishop | Input/Output: a = check? or take?, dif = positionLetter - positionDigit, amount = 1 |
Knight | Arithemtic Operations: a = check? or take?, dif = positionLetter - positionDigit, amount = 1 |
Pawn | no command, except on promotion, in which case it will evaluate like it is the promoted piece |
To turn a move into a number, it first must be a normal move -> no castle, mate or draw
for the position -> evaluate as a base 8 number, where the letter is the 10th place, both places are first reduced by 1 (to have the digits 0-7)
if the move is a take add 127 to the number
if the move is a check add 64 to the number
Additionally there are a few more commands:
Command | Description |
---|---|
0-0 |
start of loop |
0-0-0 |
jump to start of loop |
Mate or Draw | end program |
Examples
Hello World
Qa4+ b1+ Ba3 Na3+ d6 Bb8 Nxb4 a8 Bd7 Ba3 Na3+ a4 Bb5 Ra2 Qb5+ e1 Ba3 Na3+ g8 Ba3 Rf1 Ba3 Ng8+ a4 Ba3 Ne1+ a7 Ba3 Nf2+ b1 Ba3 Qb5+ e2 Ba3 #
Cat Program
0-0 Be1 Bb5 0-0-0 #