From: Pasi Kallinen Date: Thu, 24 Feb 2022 17:50:27 +0000 (+0200) Subject: Move output delay from walk_path to mhurtle_step X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6fa4fd46f765056fcf9a3d16738ba0aac2ff1035;p=nethack Move output delay from walk_path to mhurtle_step ... in case walk_path is ever used for something that doesn't need the delay. The hero hurtling already had delay, so it was done twice. --- diff --git a/src/dothrow.c b/src/dothrow.c index d71b42e12..003830fe4 100644 --- a/src/dothrow.c +++ b/src/dothrow.c @@ -637,8 +637,6 @@ walk_path(coord *src_cc, coord *dest_cc, /* check for early exit condition */ if (!(keep_going = (*check_proc)(arg, x, y))) break; - flush_screen(1); - delay_output(); } } else { while (i++ < dx) { @@ -653,8 +651,6 @@ walk_path(coord *src_cc, coord *dest_cc, /* check for early exit condition */ if (!(keep_going = (*check_proc)(arg, x, y))) break; - flush_screen(1); - delay_output(); } } @@ -926,6 +922,9 @@ mhurtle_step(genericptr_t arg, int x, int y) || res == Trap_Caught_Mon || res == Trap_Moved_Mon) return FALSE; + + flush_screen(1); + delay_output(); return TRUE; } if ((mtmp = m_at(x, y)) != 0 && (canseemon(mon) || canseemon(mtmp))) {