Hello!
I'm working on creating a few new PRC classes for a persistent world server I'm working on. The first class I'm working on is the Night Mask Deathbringer. I'm likely to work in the Swiftblade I suggested elsewhere as well as a custom Fallen Stars Pirate prc. The write-up on the Night Mask Deathbringer class can be found here-
http://dndtools.eu/classes/night-mask-deathbringer/So far, I've gotten all of the abilities to work, to a point. Right now I don't have Lesser and Greater Blood Bond checking the number of bonds against the charisma bonus but I'll get that done. I've had two errors so far and was wondering if anyone would know how to fix them.
The first error is cosmetic it seems. The class gets a bonus +2d6 sneak attack. After finding the prc_inc_sneak script I added the following-
// Night Mask Deathbringer
iClassLevel = GetLevelByClass(CLASS_TYPE_DEATHBRINGER, oPC);
if (iClassLevel) iRogueSneak += iClassLevel / 4;
When I level up past the levels that are supposed to grant the sneak dice, I see two feats for sneak attack, one saying 3d6 which is what rogue sneak is without the bonus from the class then another that says +5d6 which is 5 levels of rogue and 8 levels (+2d6) of Night Mask Deathbringer. In tests it seems the damage is 5d6 as it should be. Any way to adjust the cosmetic part of this?
And speaking of leveling, I'm getting a 'Too many instructions' error on leveling up the class that's being reported as caused by the prc_levelup script. Obviously the script itself is fine as I didn't adjust it at all. I'm figuring the error is either in my prc_nmdb script or the prc_inc_function script which I edited for the sake of the class.
Here is the short amount of code for the PRC to give the Creature of Darkness penalty to ride. I patterned it after the prc_heartwarder script and it is labeled prc_nmdb-
#include "prc_feat_const"
#include "inc_item_props"
//Creature of Darkness (Ex): Animals can sense the death in you, causing them to fear your presence.
//As a result, all animals except for bats, rats, and wolves have their initial attitudes moved down
//one category when you first approach them. In addition, you take a —2 penalty on all Ride checks due
//to the beast's inherent nervousness at your presence.
void CreatureOfDarkness(object oPC, object oSkin, int iLevel)
{
int iTest = GetPersistantLocalInt(oPC, "NWNX_NMDBCoDark");
if(!iTest)
{
SetCompositeBonus(oSkin, "CreatureOfDarkness", iLevel, ITEM_PROPERTY_DECREASED_SKILL_MODIFIER, SKILL_RIDE);
}
}
void main()
{
object oPC = OBJECT_SELF;
object oSkin = GetPCSkin(oPC);
int iCreatDark = GetHasFeat(FEAT_CREATURE_OF_DARKNESS, oPC) ? 2 : 0;
if (iCreatDark > 0) CreatureOfDarkness(oPC, oSkin, iCreatDark);
}
As for the prc_inc_function script, it's much too large to post here but I'll post the lines before as well as the changes I've made to the script.
In the switch table for SetupCharacterData function-
case CLASS_TYPE_WARMIND: sScript = "psi_warmind"; iData |= 0x01; break;
case CLASS_TYPE_WEREWOLF: sScript = "prc_werewolf"; break;
case CLASS_TYPE_WILDER: iData |= 0x01; break;
case CLASS_TYPE_WITCH: iData |= 0x03; break;
case CLASS_TYPE_DEATHBRINGER: sScript = "prc_nmdb"; break;
Added to the gathering of functions for feat uses per day-
void FeatNMDeathbringer(object oPC)
{
int iNMDBLevel = GetLevelByClass(CLASS_TYPE_DEATHBRINGER, oPC);
if (!iNMDBLevel) return;
int iUses = (iNMDBLevel + 2) / 3;
FeatUsePerDay(oPC, FEAT_HESITATING_STARE, -1, iUses);
}
added to the FeatSpecialUsesPerDay function-
FeatNMDeathbringer(oPC);
I've edited a number of 2da files such as feat.2da, spells.2da, classes.2da, prc_classes.2da, and prc_spells.2da. Includes edited are prc_class_const, prc_feat_const, prc_inc_function, prc_inc_sneak, and prc_spell_const. additions to the tlk file have been successful as well. Any ideas as to why this might be happening?