An FRC compatible xboard (sort of)
Posted: 17 Jul 2005, 23:31
Hi all,
It's been a rainy weekend in Oslo, and today I decided to kill some time by trying to hack some basic FRC support into xboard. I think all my changes are located in files which are shared between xboard and Winboard, which means that everything should work equally well (which not well at all, really) in Winboard. You can download the modified source code by clicking here.
This xboard version uses FEN strings and move encodings of the form described by Stefan Meyer Kahlen in his recent extension to the UCI protocol. It will only work with engines which send moves in coordinate notation ("e2e4", etc.). Castling moves are encoded in the form "king captures rook", e.g. "e1h1" for a white kingside castling from the standard opening position. Entering castling moves with the mouse is done in the same way, you just drop the king on top of the rook.
There are many limitations. So far, there is no legality checking at all for FRC castlings. For instance, if you launch xboard without a chess engine, in the standard starting position xboard will allow 1. O-O as white's first move (the bishop on f1 and the knight on g1 will simply disappear). It is also not possible to manually set up FRC positions. I recommend creating a text file containing all the 960 starting positions in SMK's FEN format, and load a position by starting xboard with the -lpf and -lpi command line parameters.
I also cannot promise that there are no serious bugs. I haven't had the chance to test a lot. My plan was to use my modified xboard combined with a FRC-enabled PolyGlot which I am also working on, but this modified PolyGlot is even more unfinished and not yet ready for release. I bet Fabien will have it finished before me, anyway.
If someone wants to inspect my changes to the xboard code, I have tried to surround them with comments including my name. Search for the string "Tord" in the source code, and you should be able to easily find all the important changes (I may have forgotten adding comments a couple of places, but not in important parts of the code, I think). Most of the changes are really ugly and hairy hacks, but I think they mostly work.
Have fun.
Tord
It's been a rainy weekend in Oslo, and today I decided to kill some time by trying to hack some basic FRC support into xboard. I think all my changes are located in files which are shared between xboard and Winboard, which means that everything should work equally well (which not well at all, really) in Winboard. You can download the modified source code by clicking here.
This xboard version uses FEN strings and move encodings of the form described by Stefan Meyer Kahlen in his recent extension to the UCI protocol. It will only work with engines which send moves in coordinate notation ("e2e4", etc.). Castling moves are encoded in the form "king captures rook", e.g. "e1h1" for a white kingside castling from the standard opening position. Entering castling moves with the mouse is done in the same way, you just drop the king on top of the rook.
There are many limitations. So far, there is no legality checking at all for FRC castlings. For instance, if you launch xboard without a chess engine, in the standard starting position xboard will allow 1. O-O as white's first move (the bishop on f1 and the knight on g1 will simply disappear). It is also not possible to manually set up FRC positions. I recommend creating a text file containing all the 960 starting positions in SMK's FEN format, and load a position by starting xboard with the -lpf and -lpi command line parameters.
I also cannot promise that there are no serious bugs. I haven't had the chance to test a lot. My plan was to use my modified xboard combined with a FRC-enabled PolyGlot which I am also working on, but this modified PolyGlot is even more unfinished and not yet ready for release. I bet Fabien will have it finished before me, anyway.
If someone wants to inspect my changes to the xboard code, I have tried to surround them with comments including my name. Search for the string "Tord" in the source code, and you should be able to easily find all the important changes (I may have forgotten adding comments a couple of places, but not in important parts of the code, I think). Most of the changes are really ugly and hairy hacks, but I think they mostly work.
Have fun.
Tord