/Home or play chess at
......... Google App Engine ...........
.... ....

Chess software for fun

sestdiena, 2011. gada 12. februāris

Lua chess engine

After long studies of various chess programs, I found it reasonable to port GarboChess (http://forwardcoding.com) to Lua 5.1. This seems to me the most appropriate chess engine for an interpreted programming language. The code is short, readable, smart, and gives quick answer. Very optimal for limited calculation environment.
Lua is widely used language for scripting in games. Of course, not comparable to strong chess software.
The source: garbochess.lua
Note: Lua 5.1 requires a pre-installed library for bitwise operation support - as BitOp. Lua 5.2 will contain it all by default. In fact, You just have to copy bit.dll to Lua folder.

Other Lua sources: c0_chess.lua - code library for chess logic - chess board, moves, short opening base, PGN and FEN functions, fischerrandom, samples (also ShiVa project). This library is without chess engine.
As always, it is better to use opening base, if there is a variant for given key,
and the chess engine - after.

About testing.
A chess match Garbochess Lua vs Lua, approx.thinking time 10sec for a move,
absolutely not a strong hardware:

As You see, quite sophisticated AI. Thanks to master! Implemented for real in this pinky chess project.

Another Lua chess engine.
Fruit 2.1 ported to Lua: fruit21chess.lua (10.2011)
Also plays good chess even for scripting language.
A chess match Fruit Lua vs Lua:

+other Lua chess sources:
LuaJIT based .zip file contains a
collection of lua chess engines, including described above. There are also pure lua chess programs without bitwise library requirement. Arena .abk and Polyglot .bin chess opening book reader for lua language (nov.2013). Just download, unzip and start samples from the windows command line.

Nav komentāru:

Ierakstīt komentāru