summaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorPhilipp Sehmisch <mana@crushnet.org>2010-02-24 21:51:48 +0100
committerPhilipp Sehmisch <mana@crushnet.org>2010-02-24 22:55:56 +0100
commit4cb11db37aeb8052e1fef94965bc48bbc949e7f9 (patch)
treebcd945faf1388b96be9d949d9b6d701855b70a9a /src/main.cpp
parent48131e2ecfa4d52375d890dac80f9ab1ad45ccf0 (diff)
downloadmana-client-4cb11db37aeb8052e1fef94965bc48bbc949e7f9.tar.gz
mana-client-4cb11db37aeb8052e1fef94965bc48bbc949e7f9.tar.bz2
mana-client-4cb11db37aeb8052e1fef94965bc48bbc949e7f9.tar.xz
mana-client-4cb11db37aeb8052e1fef94965bc48bbc949e7f9.zip
Added the possibility to pass a branding file by command line. Reviewed-by: Thorbjørn Lindeijer <thorbjorn@lindeijer.nl>
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 2fb9c112..aaa826cb 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -40,7 +40,7 @@ static void printHelp()
using std::endl;
std::cout
- << _("mana") << endl << endl
+ << _("mana [mana-file]") << endl << endl
<< _("Options:") << endl
<< _(" -C --config-file : Configuration file to use") << endl
<< _(" -d --data : Directory to load game data from") << endl
@@ -147,6 +147,15 @@ static void parseOptions(int argc, char *argv[], Client::Options &options)
break;
}
}
+
+ // when there are still options left use the last
+ // one as branding file
+ if (optind < argc)
+ {
+ options.brandingPath = argv[optind];
+ }
+
+
}
#ifdef WIN32