From 75335f199ea5fbc7b1af890473ec98dc340c2ae8 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jonas=20K=C3=B6lker?= Date: Mon, 5 Oct 2015 10:03:57 +0200 Subject: [PATCH 1/1] Fix Bridges keyboard cursor vertical out-of-bounds error. Position the cursor in the top (bottom) row, press enter and press up (down). The game acts as if you had pressed right, both with Enter- and Space-based dragging. --- bridges.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bridges.c b/bridges.c index 23a95f5..eb15437 100644 --- a/bridges.c +++ b/bridges.c @@ -2376,6 +2376,8 @@ static char *interpret_move(const game_state *state, game_ui *ui, int nx = ui->cur_x, ny = ui->cur_y; move_cursor(button, &nx, &ny, state->w, state->h, 0); + if (nx == ui->cur_x && ny == ui->cur_y) + return NULL; update_drag_dst(state, ui, ds, COORD(nx)+TILE_SIZE/2, COORD(ny)+TILE_SIZE/2); -- 2.30.2