From 5894f27848d3bf7ca770c06c207ee1fc627dc983 Mon Sep 17 00:00:00 2001 From: dshaligram Date: Tue, 3 Apr 2007 12:54:05 +0000 Subject: Jellies now resist acid spit (adapted jlewis' patch). On Windows and DOS, prompt for a newline after printing an error message and exiting, since users on those systems seem to run executables by double-clicking on them, and cannot see error messages because the console disappears when the game exits. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@1198 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/stuff.cc | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'crawl-ref/source/stuff.cc') diff --git a/crawl-ref/source/stuff.cc b/crawl-ref/source/stuff.cc index 31aa0de613..74c9250bdd 100644 --- a/crawl-ref/source/stuff.cc +++ b/crawl-ref/source/stuff.cc @@ -376,6 +376,14 @@ void end(int exit_code, bool print_error, const char *format, ...) error += "\n"; fprintf(stderr, "%s", error.c_str()); } + +#if defined(WIN32CONSOLE) || defined(DOS) + if (exit_code) + { + fprintf(stderr, "Hit Enter to continue...\n"); + getchar(); + } +#endif exit(exit_code); } -- cgit v1.2.3-54-g00ecf