Player Resource Consortium
Neverwinter Nights => Builders => Topic started by: Complex on November 12, 2011, 09:44:25 AM
-
Hi guys, im working on a script that needs to check whether a character has any casting class or not, i guess u guys already have some method for this so i was wondering if u recall them
id need script to tell if the character has full caster levels,
tell if character has semi-caster levels, say, ranger, paladin, etc.
thanks!
-
I would go with:
GetPrimaryArcaneClass(oPC) != CLASS_TYPE_INVALID || GetPrimaryDivineClass(oPC) != CLASS_TYPE_INVALID
or you could loop through character classes with GetClassByPosition() and than use GetIsArcaneClass()/GetIsDivineClass()
You'll find some interesting functions in prc_inc_castlvl.nss
Another function for calculating caster level is located in prc_inc_spells.nss (i don't remember where is it used though).
-
looks great xwarren, thx a lot!