diff options
author | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-07-08 00:25:58 +0000 |
---|---|---|
committer | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-07-08 00:25:58 +0000 |
commit | d0650b984a9d22727429bceb1d51a3dfb8aa84ef (patch) | |
tree | fc2affc4477918b9935d69433c8a822fcfd5c3c6 /crawl-ref/source/initfile.cc | |
parent | 12c06e3c2402f48325bf48d31e588af5ccab1c08 (diff) | |
download | crawl-ref-d0650b984a9d22727429bceb1d51a3dfb8aa84ef.tar.gz crawl-ref-d0650b984a9d22727429bceb1d51a3dfb8aa84ef.zip |
Save macro.txt and wininit.txt in the settings folder, both using the
macro_dir option. We might want to rename said option.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@6447 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/initfile.cc')
-rw-r--r-- | crawl-ref/source/initfile.cc | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/crawl-ref/source/initfile.cc b/crawl-ref/source/initfile.cc index 098db26920..08ca799cb2 100644 --- a/crawl-ref/source/initfile.cc +++ b/crawl-ref/source/initfile.cc @@ -1134,10 +1134,10 @@ static std::string _find_crawlrc() } // Check all possibilities for init.txt - for ( int i = 0; locations_data[i][1] != NULL; ++i ) + for (int i = 0; locations_data[i][1] != NULL; ++i) { // Don't look at unset options - if ( locations_data[i][0] != NULL ) + if (locations_data[i][0] != NULL) { const std::string rc = catpath(locations_data[i][0], locations_data[i][1]); @@ -1808,7 +1808,7 @@ void game_options::read_option_line(const std::string &str, bool runscript) // Keep unlowercased field around const std::string orig_field = field; - if (key != "name" && key != "crawl_dir" + if (key != "name" && key != "crawl_dir" && key != "macro_dir" && key != "race" && key != "class" && key != "ban_pickup" && key != "autopickup_exceptions" && key != "stop_travel" && key != "sound" @@ -2174,6 +2174,10 @@ void game_options::read_option_line(const std::string &str, bool runscript) // if the user puts two crawl_dir lines in the init file. SysEnv.crawl_dir = field; } + else if (key == "macro_dir") + { + macro_dir = field; + } #endif else if (key == "race") { @@ -3039,10 +3043,10 @@ void get_system_environment(void) } #endif - // The full path to the init file -- this over-rides CRAWL_DIR + // The full path to the init file -- this overrides CRAWL_DIR. SysEnv.crawl_rc = check_string( getenv("CRAWL_RC") ); - // rename giant and giant spiked clubs + // Rename giant and giant spiked clubs. SysEnv.board_with_nail = (getenv("BOARD_WITH_NAIL") != NULL); #ifdef MULTIUSER |