diff options
author | PikalaxALT <pikalaxalt@gmail.com> | 2021-05-29 18:45:31 -0400 |
---|---|---|
committer | PikalaxALT <pikalaxalt@gmail.com> | 2021-05-29 18:45:31 -0400 |
commit | 79e77921c30109d29c3d791099aa42696c25ba99 (patch) | |
tree | 88804ef7b70137365d15afceaee9872d2c7b9890 /tools/knarc/Source.cpp | |
parent | 06c43a0f10dc2afc08bf36311cd3b502c291df65 (diff) |
Output NARC contents as C enums in .naix files
You can include these by typing out the full path to the .naix file
(minus the files/ prefix). Example:
```c
```
Also:
- Build the filesystem before building the C objects
Diffstat (limited to 'tools/knarc/Source.cpp')
-rw-r--r-- | tools/knarc/Source.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tools/knarc/Source.cpp b/tools/knarc/Source.cpp index d9a5cf83..587c8527 100644 --- a/tools/knarc/Source.cpp +++ b/tools/knarc/Source.cpp @@ -8,6 +8,7 @@ using namespace std; bool debug = false; bool pack_no_fnt = true; +bool output_header = false; void PrintError(NarcError error) { @@ -40,6 +41,7 @@ static inline void usage() { cout << "\t-n\tBuild the filename table (default: discards filenames)" << endl; cout << "\t-D/--debug\tPrint additional debug messages" << endl; cout << "\t-h/--help\tPrint this message and exit" << endl; + cout << "\t-i\tOutput a .naix header" << endl; } int main(int argc, char* argv[]) @@ -104,6 +106,9 @@ int main(int argc, char* argv[]) else if (!strcmp(argv[i], "-n")) { pack_no_fnt = false; } + else if (!strcmp(argv[i], "-i")) { + output_header = true; + } else { usage(); cerr << "ERROR: Unrecognized argument: " << argv[i] << endl; |