From e39198243f99fae49befe7489b3f16ad6556b835 Mon Sep 17 00:00:00 2001 From: dshaligram Date: Fri, 17 Aug 2007 22:30:02 +0000 Subject: Fixed -morgue option being ignored when Crawl is built with Lua bindings (Marc). Dropped generation odds of Pan demons post-Orb. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@2011 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/initfile.cc | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'crawl-ref/source/initfile.cc') diff --git a/crawl-ref/source/initfile.cc b/crawl-ref/source/initfile.cc index c7c762b932..e084e3d546 100644 --- a/crawl-ref/source/initfile.cc +++ b/crawl-ref/source/initfile.cc @@ -530,7 +530,7 @@ void game_options::reset_options() save_dir.clear(); #endif -#ifndef SHORT_FILE_NAMES +#if !defined(SHORT_FILE_NAMES) && !defined(SAVE_DIR_PATH) morgue_dir = "morgue/"; #endif @@ -1870,22 +1870,24 @@ void game_options::read_option_line(const std::string &str, bool runscript) { remember_name = read_bool( field, remember_name ); } +#ifndef SAVE_DIR_PATH else if (key == "save_dir") { // If SAVE_DIR_PATH was defined, there are very likely security issues // with allowing the user to specify a different directory. -#ifndef SAVE_DIR_PATH save_dir = field; -#endif } +#endif else if (key == "show_turns") { show_turns = read_bool( field, show_turns ); } +#ifndef SAVE_DIR_PATH else if (key == "morgue_dir") { morgue_dir = field; } +#endif else if (key == "hp_warning") { hp_warning = atoi( field.c_str() ); @@ -2785,7 +2787,7 @@ bool parse_args( int argc, char **argv, bool rc_only ) if (!next_is_param) return (false); if (!rc_only) - Options.morgue_dir = next_arg; + SysEnv.morgue_dir = next_arg; nextUsed = true; break; -- cgit v1.2.3-54-g00ecf