aboutsummaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorJuhani Numminen <juhaninumminen0@gmail.com>2012-01-27 14:56:45 +0200
committerPerttu Ahola <celeron55@gmail.com>2012-02-28 21:03:45 +0200
commit79326e6287153c5eb1ecf03a12101bf8e46bf69b (patch)
treef89e6095acd01b7608c3f23fa3077c0ac7ba75d0 /src/main.cpp
parentc8ec71150363ce146830ab72790eee2c598e4589 (diff)
downloadminetest-79326e6287153c5eb1ecf03a12101bf8e46bf69b.tar.gz
minetest-79326e6287153c5eb1ecf03a12101bf8e46bf69b.tar.bz2
minetest-79326e6287153c5eb1ecf03a12101bf8e46bf69b.zip
Add descriptions to command line arguments
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp27
1 files changed, 18 insertions, 9 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 6cb9cf984..2875474f1 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -1085,22 +1085,31 @@ int main(int argc, char *argv[])
// List all allowed options
core::map<std::string, ValueSpec> allowed_options;
- allowed_options.insert("help", ValueSpec(VALUETYPE_FLAG));
+ allowed_options.insert("help", ValueSpec(VALUETYPE_FLAG,
+ "Show allowed options"));
allowed_options.insert("server", ValueSpec(VALUETYPE_FLAG,
"Run server directly"));
allowed_options.insert("config", ValueSpec(VALUETYPE_STRING,
"Load configuration from specified file"));
- allowed_options.insert("port", ValueSpec(VALUETYPE_STRING));
- allowed_options.insert("address", ValueSpec(VALUETYPE_STRING));
- allowed_options.insert("random-input", ValueSpec(VALUETYPE_FLAG));
- allowed_options.insert("disable-unittests", ValueSpec(VALUETYPE_FLAG));
- allowed_options.insert("enable-unittests", ValueSpec(VALUETYPE_FLAG));
- allowed_options.insert("map-dir", ValueSpec(VALUETYPE_STRING));
+ allowed_options.insert("port", ValueSpec(VALUETYPE_STRING,
+ "Set network port to connect to"));
+ allowed_options.insert("address", ValueSpec(VALUETYPE_STRING,
+ "Address to connect to"));
+ allowed_options.insert("random-input", ValueSpec(VALUETYPE_FLAG,
+ "Enable random user input, for testing"));
+ allowed_options.insert("disable-unittests", ValueSpec(VALUETYPE_FLAG,
+ "Disable unit tests"));
+ allowed_options.insert("enable-unittests", ValueSpec(VALUETYPE_FLAG,
+ "Enable unit tests"));
+ allowed_options.insert("map-dir", ValueSpec(VALUETYPE_STRING,
+ "Map directory (where everything in the world is stored)"));
#ifdef _WIN32
allowed_options.insert("dstream-on-stderr", ValueSpec(VALUETYPE_FLAG));
#endif
- allowed_options.insert("speedtests", ValueSpec(VALUETYPE_FLAG));
- allowed_options.insert("info-on-stderr", ValueSpec(VALUETYPE_FLAG));
+ allowed_options.insert("speedtests", ValueSpec(VALUETYPE_FLAG,
+ "Run speed tests"));
+ allowed_options.insert("info-on-stderr", ValueSpec(VALUETYPE_FLAG,
+ "Print debug information to console"));
Settings cmd_args;