-
Notifications
You must be signed in to change notification settings - Fork 3
Description
First of all, this is a K1 script. K1 nwscript.nss was used to compile it. It compiles with both standalone nwnsscomp.exe (ripped from a deNCS install) and the TSLPatcher modified nwnsscomp.exe.
Attempting to compile k_ai_master.nss (with these source files) with the built-in compiler as-is (through holopatcher) results in an error:
[Error] [15:22:25] Function 'FinesseMeleeWeapons' has not been defined.
If the following two define lines are added to the beginning of k_inc_statfix.nss, the file compiles and the mod works:
void FinesseMeleeWeapons(int depth = 0, int IsHen = 0);
void RepeaterAttacks(int depth = 0, int IsHen = 0);
For what it's worth, nwnsscomp.exe compiles with those unnecessary defines as well.
I also encountered an extra compiler error earlier. Since I'm not using an IDE for .nss files, I had the following define included in the beginning of k_inc_statfix.nss so I could use NPP's autocomplete:
int CheckAppliedEffect(object oCreature, int EffectType, int EffectSubType = SUBTYPE_MAGICAL);
This is obviously not proper, since that function (which is part of k_inc_genutil) is included earlier in k_ai_master as part of
#include "k_inc_genutil"
#include "k_inc_statfix"
Despite this, nwnsscomp.exe compiled the file properly. Trying to compile with that define using the built-in compiler gives the following error:
[Error] [15:24:55] Function 'CheckAppliedEffect' already has a prototype or been defined.
I'm including the full holopatcher error logs for these as well as the source files (including the vanilla files necessary for compiling k_ai_master):