omnicoder wrote:I'm curious, why does it require steam to be running, since it seems to read ClientRegistry itself and uses HLLib?
Unlike Pakrat, PackBSP doesn't do any direct byte-level modification to your map files, but delegates to Valve's bspzip.exe SDK tool. For whatever reason Valve made bspzip like hammer: Unable to run without Steam.
While I
could write something to directly do the packing on a byte-by-byte level, I'd rather just make it bspzip's problem, since that's the "standard" way from Valve. I currently have stuff that does byte-level
reading of BSPs, but even there there's a bunch of junk involving version numbers and detecting the difference between newer and older map formats etc...
At first I misunderstood your question, but since I wrote it out anyway... There are two reasons PackBSP needs to access ClientRegistry.
- App dependencies. I know Team Fortress 2 is "App ID 440", but where do I go from there? The CR has information saying that App 440 needs 441, 442, 443, and various IDs that are "shared" by all Source games. Other games have other IDs with other dependencies.
- ID to GCF mappings. What does "442" really mean, anyway? The CR has information telling me that those correspond to "Team Fortress 2 Materials", so now I know what GCF to open.