FEN format
FEN format is a text string representation of a chess placement. Strange or reasonable! Chinese Chess is very similar to International Chess. The International Chess format can directly adopt.
Example: "rnbakabnr//1c5c/p1p1p1p1p///P1P1P1P1P/1C5C//RNBAKABNR w - - 0 1/x04"
Click the first line and press down arrow on keyboard to animate the move (It's true, Google BLOG can do things like that !):
Here is the brief explanation:
"KRNCABP" (white side) are same as "帥車馬包仕相兵" (red side). These Chinese characters are just my personal favourite!
"krncabp" (black side) are same as "將車馬炮士象卒" (green side)
The rows are delimited by '/', there are at most 10 rows on the chessboard. The numeric between the chess letters are the number of spaces. Any unrecognised letters are treated as 1, i.e. a space.
The letter followed ('w' in the example) is the side to move. 'w', 'W', 'r' or 'R' means red to move. 'b', 'B', 'g', or 'G' means green to move.
The last numeric (1 in the example) is the move number. The other letters('- - 0') are not used, just in compliant with the original FEN format.
I added the new feature like '/x04' in the example to denote the last picked chess, the first digit is the row number(0 means the topmost row) the last digit is the position counted from the left(0 means leftmost). This new feature is optional.

0 個意見:
張貼留言
訂閱 張貼留言 [Atom]
<< 首頁