Hi All,
I make use of the OC HenchTalentAdvancedBuff function to prepare some creatures ahead of an encounter. However, I have found that in some occasions the creature that is supposed to cast the buff spell fails.
NB: In DEBUG testing, I bypass this function and do a direct call to cast the spell I have in mind, with the *only* difference being I use the CHEAT parameter in the calling, suggesting my creature *fails* to meet the criteria to cast the said spell.
E.g. If I use this line from the function (edited with the CHEAT parameter), the creature casts the spell just fine:-
ActionCastSpellAtLocation(SPELL_SUMMON_CREATURE_I, GetLocation(OBJECT_SELF), METAMAGIC_NONE, TRUE, PROJECTILE_PATH_TYPE_DEFAULT, TRUE);
Here is the full code with debug to show what I mean:-
NB: The send message is a homebrew debug. The function here should simply cast the spell if present. It does not. Uncomment my "cheat" version of the same line of code that is supposed to cast the spell and it does!
Note also, the feedback has the cleric come back at 3rd level and with 16 Wisdom.
Does anybody know what else the "CHEAT" parameter includes in its checking, in case I am missing something?
Thanks in advance,
Lance.
if(HenchTalentAdvancedBuff(40.0))
{
SendMessageToAllPCs(GetName(OBJECT_SELF) + " <<< BUFFING C >>> " + FloatToString(GetDistanceBetween(OBJECT_SELF,oNearestPC )));
if(GetHasSpell(174))
{
//ActionCastSpellAtLocation(SPELL_SUMMON_CREATURE_I, GetLocation(OBJECT_SELF), METAMAGIC_NONE, TRUE, PROJECTILE_PATH_TYPE_DEFAULT, TRUE);
SendMessageToAllPCs(GetName(OBJECT_SELF) + " <<< HAS SPELL >>> " + " IS LEVEL >>> " + IntToString(GetLevelByClass(CLASS_TYPE_CLERIC)) + " HAS WISDOM >>> " + IntToString(GetAbilityScore(OBJECT_SELF, ABILITY_WISDOM, FALSE)));
}
}





Retour en haut






