diff options
author | dshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-05-26 15:30:07 +0000 |
---|---|---|
committer | dshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-05-26 15:30:07 +0000 |
commit | a844f8e10213c19b6e48d6ff98e97bc9f026a42a (patch) | |
tree | 9cada2344ca78a2c2de555dc8b7fa943ee7382fe /crawl-ref/source/acr.cc | |
parent | 1f1939b11a6ed95f769644c21e53589a1e7abeb9 (diff) | |
download | crawl-ref-a844f8e10213c19b6e48d6ff98e97bc9f026a42a.tar.gz crawl-ref-a844f8e10213c19b6e48d6ff98e97bc9f026a42a.zip |
Better support for settings files that include other files:
- Files can be included as "include foo" in .crawlrc instead of using
the Lua call: : crawl.read_options('foo'). include foo and the Lua
crawl.read_options('foo') are not equivalent - Lua only runs after the
start of a new game, which is too late for some option settings.
- Crawl searches for included files in this sequence:
- Absolute paths: use the path directly (but not if DATA_DIR_PATH is
set, since we don't want Crawl to read arbitrary files on
multiuser systems).
- Search relative to the including file.
- Search relative to any -rcdir(s) provided.
- Search in the data file search path.
- The data file search path now includes settings/ for when we move rc
stuff to settings/
.gitignore: ignore saves and morgue dirs correctly.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5256 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/acr.cc')
-rw-r--r-- | crawl-ref/source/acr.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/crawl-ref/source/acr.cc b/crawl-ref/source/acr.cc index 397abc48dd..0f96a4f61e 100644 --- a/crawl-ref/source/acr.cc +++ b/crawl-ref/source/acr.cc @@ -155,7 +155,7 @@ game_state crawl_state; -std::string init_file_location; // externed in newgame.cc +std::string init_file_error; // externed in newgame.cc char info[ INFO_SIZE ]; // messaging queue extern'd everywhere {dlb} @@ -225,7 +225,7 @@ int main( int argc, char *argv[] ) init_monsters(mcolour); // Read the init file. - init_file_location = read_init_file(); + init_file_error = read_init_file(); // now parse the args again, looking for everything else. parse_args( argc, argv, false ); @@ -294,6 +294,7 @@ static void _show_commandline_options_help() puts(" -plain don't use IBM extended characters"); puts(" -dir <path> crawl directory"); puts(" -rc <file> init file name"); + puts(" -rcdir <dir> directory that contains (included) rc files"); puts(" -morgue <dir> directory to save character dumps"); puts(" -macro <dir> directory to save/find macro.txt"); puts(""); |