diff options
| author | Mike Buland <eichlan@xagasoft.com> | 2012-01-04 00:31:46 -0700 | 
|---|---|---|
| committer | Mike Buland <eichlan@xagasoft.com> | 2012-01-04 00:31:46 -0700 | 
| commit | 8f3b08c826f1174019386c0bfe22627bb269123d (patch) | |
| tree | 1c9b0bcb10f32a64b6b268316856762e6c6b6a0d /src/options.cpp | |
| parent | d8f0276ec9d3b538a5ef8918a3072e3528a480d5 (diff) | |
| download | stage-8f3b08c826f1174019386c0bfe22627bb269123d.tar.gz stage-8f3b08c826f1174019386c0bfe22627bb269123d.tar.bz2 stage-8f3b08c826f1174019386c0bfe22627bb269123d.tar.xz stage-8f3b08c826f1174019386c0bfe22627bb269123d.zip  | |
Attempt to generate version.h from git.
Diffstat (limited to 'src/options.cpp')
| -rw-r--r-- | src/options.cpp | 25 | 
1 files changed, 25 insertions, 0 deletions
diff --git a/src/options.cpp b/src/options.cpp new file mode 100644 index 0000000..7953add --- /dev/null +++ b/src/options.cpp  | |||
| @@ -0,0 +1,25 @@ | |||
| 1 | #include "options.h" | ||
| 2 | #include "version.h" | ||
| 3 | |||
| 4 | #include <bu/optparser.h> | ||
| 5 | |||
| 6 | Options::Options() | ||
| 7 | { | ||
| 8 | } | ||
| 9 | |||
| 10 | Options::~Options() | ||
| 11 | { | ||
| 12 | } | ||
| 13 | |||
| 14 | void Options::parse( int argc, char *argv[] ) | ||
| 15 | { | ||
| 16 | Bu::OptParser opt; | ||
| 17 | |||
| 18 | opt.addHelpBanner("STAGE v" FULLVER | ||
| 19 | " - Simple, Textual, Adventure Game Environment"); | ||
| 20 | opt.addHelpBanner("usage: " + Bu::String(argv[0]) + | ||
| 21 | " [options] <filename>\n"); | ||
| 22 | opt.addHelpOption('h', "help"); | ||
| 23 | opt.parse( argc, argv ); | ||
| 24 | } | ||
| 25 | |||
