summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/stuff.cc
diff options
context:
space:
mode:
Diffstat (limited to 'crawl-ref/source/stuff.cc')
-rw-r--r--crawl-ref/source/stuff.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/crawl-ref/source/stuff.cc b/crawl-ref/source/stuff.cc
index a9bde6fb46..8525c56113 100644
--- a/crawl-ref/source/stuff.cc
+++ b/crawl-ref/source/stuff.cc
@@ -703,7 +703,7 @@ void canned_msg(unsigned char which_message)
// jmf: general helper (should be used all over in code)
// -- idea borrowed from Nethack
bool yesno( const char *str, bool safe, int safeanswer, bool clear_after,
- bool interrupt_delays )
+ bool interrupt_delays, bool noprompt )
{
unsigned char tmp;
@@ -711,7 +711,8 @@ bool yesno( const char *str, bool safe, int safeanswer, bool clear_after,
interrupt_activity( AI_FORCE_INTERRUPT );
for (;;)
{
- mpr(str, MSGCH_PROMPT);
+ if ( !noprompt )
+ mpr(str, MSGCH_PROMPT);
tmp = (unsigned char) getch();
@@ -733,7 +734,7 @@ bool yesno( const char *str, bool safe, int safeanswer, bool clear_after,
return false;
else if (tmp == 'Y')
return true;
- else
+ else if (!noprompt)
mpr("[Y]es or [N]o only, please.");
}
} // end yesno()