Preloading haks is well documented on the RPG Modding Forums - its the system I use for NwnE. Combined with the override, its the only way to deliver cross-module content without cluttering up the modules.
http://www.rpgmoddin...ghlight=Preload
The nice thing about preloading is the flexibility of the system. You can define the directory the haks are loaded from (the game default is /patch) and easily switch out systems and rulesets just by using a different patch.ini folder - there is no need to change the name of the haks. Furthermore, the amount of haks you can preload appears to be unlimited - I have preloaded as many as 16 haks and never experienced an issue.
I also use the override folder in conjunction with preloading for NwnE. This was necessary because Cervantes and I decided that we did not want to clutter the custom palettes with all the CC we were adding (like the CEP does). The NwnE override folder houses all the itp, template (utc, utp, uti, etc.), and script (nss and ncs) files. The mechanics of the override are thus:
1. NSS and NCS files in a hak cannot be overwritten by the module builder. When the module is compiled, the hak versions will overwrite any changes you have made. However, they can be overwritten if the files are included in the override (Note - if you are overwriting a standard resources you need to include both the nss and ncs files).
2. Template files in a hak will appear on the custom palette. If added to one of the standard itp files, the templates will appear on both the standard and custom palettes.
3. When overwriting standard game resources, TGA files belong in the override and DDS files belong in a hak. For some reason, TGA files in a hak will NOT overwrite standard resources. Likewise, DDS files in the override will NOT overwrite standard resources.
Another aspect of preloading is that any haks loaded through this method do not count against the module hak limit. For example, if you are using CEP you could preload all the CEP content and then have a range of haks attached to your module. You would only need to associate the CEP tlk with your module. This greatly reduces the size of the module when loading, since the CEP content would be loaded before the module loads. It also reduces lag.
Note - for multiplayer servers: Players logging into the server will have to preload resources. It is not something that can be done solely on the server-side.
Modifié par Pstemarie, 25 septembre 2010 - 10:33 .