curses message suppression
The curses interface was using 'moves' as if it meant "moves" rather than "turns". Typing ESC at >> (curses' terser version of --More--) prompt would suppress messages for the rest of the current turn rather than just the rest of the current move. So if the hero got an extra move due to being Fast, there would be no feedback during that move.
This commit is contained in:
@@ -17,6 +17,8 @@
|
||||
#define strncasecmp strncmpi
|
||||
#endif
|
||||
|
||||
extern long curs_mesg_suppress_turn; /* from cursmesg.c */
|
||||
|
||||
/*
|
||||
* Note:
|
||||
*
|
||||
@@ -120,6 +122,10 @@ curses_line_input_dialog(const char *prompt, char *answer, int buffer)
|
||||
int height = prompt_height;
|
||||
char input[BUFSZ];
|
||||
|
||||
/* if messages were being suppressed for the remainder of the turn,
|
||||
re-activate them now that input is being requested */
|
||||
curs_mesg_suppress_turn = -1;
|
||||
|
||||
if (buffer >= (int) sizeof input)
|
||||
buffer = (int) sizeof input - 1;
|
||||
maxwidth = term_cols - 2;
|
||||
@@ -201,6 +207,10 @@ curses_character_input_dialog(const char *prompt, const char *choices,
|
||||
boolean any_choice = FALSE;
|
||||
boolean accept_count = FALSE;
|
||||
|
||||
/* if messages were being suppressed for the remainder of the turn,
|
||||
re-activate them now that input is being requested */
|
||||
curs_mesg_suppress_turn = -1;
|
||||
|
||||
if (invent || (moves > 1)) {
|
||||
curses_get_window_size(MAP_WIN, &map_height, &map_width);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user