From: Carl Worth Date: Mon, 3 Mar 2008 17:46:32 +0000 (-0800) Subject: Provide explanation with 'illegal move' error messages X-Git-Url: https://git.cworth.org/git?p=loudgame;a=commitdiff_plain;h=8666f33e3f4037ecad58d27897eb7ce74aec0685 Provide explanation with 'illegal move' error messages --- diff --git a/lg-loa.c b/lg-loa.c index b18b27d..4bf6230 100644 --- a/lg-loa.c +++ b/lg-loa.c @@ -47,9 +47,10 @@ loa_game_move (loa_game_t *game, const char * peer, char *error; if (! loa_board_move (&game->board, x1, y1, x2, y2, &error)) { - loudgame_sendf (&game->lg, peer, "Illegal move: %c%d%c%d", + loudgame_sendf (&game->lg, peer, "Illegal move: %c%d%c%d: %s", 'a' + x1, LOA_BOARD_SIZE - y1, - 'a' + x2, LOA_BOARD_SIZE - y2); + 'a' + x2, LOA_BOARD_SIZE - y2, + error); return FALSE; }