Hello! I have a few questions regarding the use of NWNScriptCompiler with NWN1 modules. I'm running the compiler on Ubuntu 14.04 x64 using Wine and it works as expected, but I'm trying to optimize the way I keep includes around.
I was hoping switches -1 -i would allow me to specify resource archives in order to avoid keeping extracted nss around, but I am having trouble compiling. Take for instance nwscript.nss contained in NWN/data/2da.bif. Is it possible to specify the [path to] .bif only? Example commands;
I. ./NWNScriptCompiler.exe -1 -i ../../src/data/2da/* -v1.69 -q -g -e -o -b ../ncs test.nss
II. ./NWNScriptCompiler.exe -1 -i \"${nwn_installdir}/NWN/data/\" -v1.69 -q -g -e -o -b ../ncs test.nss
I. works since src/data/2da/ contains nwscript.nss, but II., which contains 2da.bif, fails.
Questions:
- What does -1 influence?
- What is the expected contents of pathspec directories?
- Can I use -i to reference resource archives or must it be extracted sources?
- If yes on 3; can it read .hak?
- If no on 3; can it be done using a different switch?
NWNScriptCompiler - built Jan 29 2014 19:24:04
Copyright © 2008-2014 Skywing.
Portions copyright © 2002-2003, Edward T. Smith.
Portions copyright © 2003, The Open Knights Consortium.
Usage:
NWNScriptCompiler [-1acdegjkloq] [-b batchoutdir] [-h homedir]
[[-i pathspec] ...] [-m resref] [-n installdir]
[-r modpath] [-v#] [-x errprefix] [-y]
infile [outfile|infiles]
batchoutdir - Supplies the location at which batch mode places
output files and enables multiple input filenames.
homedir - Per-user NWN2 home directory (i.e. Documents\NWN2).
pathspec - Semicolon separated list of directories to search for
additional includes.
resref - Resource name of module to load (without extension).
Note that loading a module is potentially slow.
installdir - Per-machine NWN2 install directory.
modpath - Supplies the full path to the .mod (or directory) that
contains the module.ifo for the module to load. This
option overrides the [-r resref] option.
errprefix - Prefix string to prepend to compiler errors (replacing
the default of "Error").
-1 - Assume NWN1-style module and KEY/BIF resources instead of
NWN2-style module and ZIP resources.
-a - Analyze generated code and verify that it is consistent
(increases compilation time).
-c - Compile the script (default, overrides -d).
-d - Disassemble the script (overrides -c).
-e - Enable non-BioWare extensions.
-g - Suppress generation of .ndb debug symbols file.
-j - Show where include file are being sourced from.
-k - Show preprocessed source text to console output.
-l - Load base game resources even if -m isn't supplied (slow),
so that "in-box" standard includes can be resolved.
-o - Optimize the compiled script.
-p - Dump internal PCode for compiled script contributions.
-q - Silence most messages.
-vx.xx - Set the version of the compiler.
-y - Continue processing input files even on error.
PS: If there exists documentation other than the above executable dump I would be very happy to be pointed in the right direction.
PPS: Awesome compiler! TYVM!