Catalog · How the catalog works
eschecs-6
Chess GUI written in Pascal, supporting CECP and UCI protocols
- ★ 1 on Codeberg
Anyone may press Interesting, signed in or not. It helps others find this project.
README
Eschecs 6
An application to play chess against a UCI or CECP chess engine.

Written in Pascal, with MSEgui.
Usage
./eschecs [-debug] [-debugfile FILE] [--soundfont=FILE] [engines.json | engine [uci|cecp]]Engines are listed in engines.json, next to the executable, or in the JSON file given as parameter. The format is the one of Cute Chess: name, command and protocol (uci or xboard) are required; workingDirectory, arguments and options are optional. A relative working directory is relative to the JSON file.
[
{
"name" : "Cheng",
"command" : "./cheng",
"protocol" : "uci",
"workingDirectory" : "engines/cheng"
}
]On Windows, .exe is added to the command when needed, so the same file works on both systems.
An engine can also be given directly. Without protocol, UCI is tried first, then CECP.
The default engine is Durandal, a simple UCI engine whose source code is in engines/durandal.
Chess960 games are available when the selected engine supports them. To castle, move the king onto the rook.
In the opening, the computer plays moves from the Polyglot book books/Perfect2019.bin, chosen at random according to their weights, as long as the position is in the book; then the engine takes over. The book can be disabled in the Options menu. It is not used in Chess960 games.
Games are saved in eschecs.pgn, at the end of each game or with Ctrl+S.
A log is written in eschecs.log, next to the executable. With -debug, it also contains the lines sent to the engine (>) and received from it (<). With -debugfile FILE, the same log is written in FILE instead.
Engine information
In engines.json, Eschecs also reads an optional field of its own, shown in the About the engine window: author. This field takes precedence over the author announced by a UCI engine; it is the only way to show the author of an xboard engine.
The same window shows the logo of the engine, read from a file named logo.png or logo.bmp in its working directory. The logo is shown in an area of 100 × 50 pixels, one of the two usual sizes of engine logos (the other one is 130 × 65). A larger image is scaled down; a smaller one is shown as is.
Building
Either with make:
make MSEDIR=/path/to/mseide-msegui/or by opening source/eschecs.prj in MSEide and building the project. In both cases, the executable is written to the root of the repository, next to engines.json. Only make also builds the Durandal engine, in place in engines/durandal.
The appearance is chosen at compile time: a color palette, in source/appearance/palettes (sepia by default, or blue), and a skin, in source/appearance/skins (flat by default, or gradient, which fills the menu bar, the menus and the background of the windows with gradients). With make:
make PALETTE=blue SKIN=gradientIn MSEide, replace appearance/palettes/sepia/ and appearance/skins/flat/ in the unit directories of the project options.
Sounds are played through MIDI: an ALSA synthesizer (e.g. FluidSynth started with fluidsynth -a pulseaudio -m alsa_seq -i -s FILE.sf2; TiMidity++ is not detected) or the FluidSynth library with a SoundFont on Linux, the Windows MIDI mapper on Windows. Without them, Eschecs runs without sound. With --soundfont=FILE, the FluidSynth library loads FILE instead of the first SoundFont found in /usr/share/sounds/sf2 or /usr/share/soundfonts; this option has no effect when an ALSA synthesizer is available.
Other make targets:
make dist: build the distribution archive;make install-desktop: add Eschecs 6 to the desktop menu (Linux).
Credits
The chessboard is based on the MSEgui chessboard example by Martin Schreiber.
The opening book Perfect2019.bin is part of the Perfect 2019 opening books by Sedat Canbaz.
The piece sets come from freeware TrueType chess fonts:
- Alpha by Eric Bentzen;
- Adventurer, Alfonso-X, Condal, Harlequin, Kingdom, Line, Lucena, Magnetic, Mark and Marroquin by Armando Hernández Marroquín;
- Usual by Alastair Scott, redesigned by Armando Hernández Marroquín;
- Montreal by Gary Katch.

