CLI
The command-line interface for inspecting, converting, packing, unpacking, and managing NWN resources.
Why This Exists
This tool exposes the most common operations — inspect, convert, pack, unpack, and nwsync — behind a single executable so contributors and modders can work with NWN assets from a terminal without writing any code.
Quick Start
Install from the repository:
Build or run the CLI from the workspace root:
Useful patterns:
- scaffold a project with
nwproject.tomlandnwproject.lockusingneworinit - compile
.nssto.ncswithpackusing a siblingnwscript.nss, or override it with--langspec - pack directories containing
.nssin parallel by default; use-jto override the worker count - skip entrypoint validation for include-like scripts with
--no-entrypoint-check - unpack raw
.ncsto.ncs.asm, edit it, andpackit back into bytecode - lower compiled
MDLfiles to canonical ASCII withconvert - rebuild compiled
MDLbytes from canonical ASCII generated byconvert - export static
MDLgeometry to flattenedOBJ - export equipped player
UTCblueprints to flattenedOBJusing install-backed model resolution - unpack a KEY/BIF set, preserve
nwproject.lock, and repack without losing archive ordering - package an install-backed resource view into a slim server key/bif set with
pack KEY_NAME OUTPUT_DIR - open an install with
nwnrs-types::install, then query resources throughnwnrs_types::resman
CLI Behavior and Supported Commands
Each command is implemented in its own source file:
The NWScript compile helpers now live behind pack and are implemented in: