summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/initfile.cc
diff options
context:
space:
mode:
authordshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573>2007-01-11 07:32:06 +0000
committerdshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573>2007-01-11 07:32:06 +0000
commit4ddca565ae4b6e57e3445e9f4ff6f072ff0036e5 (patch)
tree3b93f632312a72d19f7dd2b8fece3d36bdaaa9d0 /crawl-ref/source/initfile.cc
parent184022aa4b8b6adcdd3452c371cae6d34b9b77fd (diff)
downloadcrawl-ref-4ddca565ae4b6e57e3445e9f4ff6f072ff0036e5.tar.gz
crawl-ref-4ddca565ae4b6e57e3445e9f4ff6f072ff0036e5.zip
Handle morgue_dir option better (create dir if it doesn't exist), updated
makefile.unix to copy docs to the data directory for make install. Added SAVEDIR variable to the makefile so the user doesn't need to edit AppHdr.h for SAVE_DIR_PATH. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@831 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/initfile.cc')
-rw-r--r--crawl-ref/source/initfile.cc10
1 files changed, 9 insertions, 1 deletions
diff --git a/crawl-ref/source/initfile.cc b/crawl-ref/source/initfile.cc
index e6300d9c21..58bc9105e9 100644
--- a/crawl-ref/source/initfile.cc
+++ b/crawl-ref/source/initfile.cc
@@ -1173,10 +1173,18 @@ void game_options::read_options(InitLineInput &il, bool runscript)
#endif
Options.explore_stop |= Options.explore_stop_prompt;
-
+
+ validate_options();
+}
+
+void game_options::validate_options()
+{
// Validate save_dir
if (!check_dir("Save directory", save_dir))
end(1);
+
+ if (!check_dir("Morgue directory", morgue_dir))
+ end(1);
}
static int str_to_killcategory(const std::string &s)