Closed barneycarroll closed 11 years ago
https://github.com/glinscott/Garbochess-JS/blob/master/js/boardui.js is the code for interfacing with the worker. Look for the g_backgroundEngine.postMessage() calls.
The moves are formatted as "from square, to square", not in SAN. So, for example, "e4" then "Nc6" would be "e2e4" then "b8c6".
There's a neat little
onmessage
listener at the bottom of garbochess.js that implies a decoupling of player 2 from the AI. I've tried sending simple SAN moves, but I always get abusted! (FEN description)
alert response. What's the right way to use this?