Tue, 28 Apr 2026 12:33:22 +0200
add message when a pre-move failed
relates to #817
| src/game.c | file | annotate | diff | comparison | revisions |
--- a/src/game.c Tue Apr 28 12:25:48 2026 +0200 +++ b/src/game.c Tue Apr 28 12:33:22 2026 +0200 @@ -342,6 +342,7 @@ /* read move */ if (use_premove || asyncgetnstr(movestr, &bufpos, MOVESTR_BUFLEN)) { + bool was_premove = use_premove; use_premove = false; if (strncmp(movestr, "resign", MOVESTR_BUFLEN) == 0) { gamestate->resign = 1; @@ -420,7 +421,11 @@ } break; default: - eval_move_failed_msg(eval_result); + if (was_premove) { + printw("\nThe prepared move could not be executed."); + } else { + eval_move_failed_msg(eval_result); + } } clrtoeol(); }