Player Resource Consortium

 

Author Topic: Inability to acquire a certain epic feat  (Read 6809 times)

0 Members and 1 Guest are viewing this topic.

October 20, 2010, 10:22:54 PM

What's up, folks? The problems with basic character creation and dynamic item property allocation having been solved, I now have come across a new quandry. This one concerns the Ignore Material Components epic feat.

My character has all the prerequisites for the IMC feat (i.e., ability to cast 9th level arcane / divine spells, Spellcraft 25 ranks, Eschew Material Components, epic character), so one would think that I'd be able to select this frigging feat as either a standard feat (the one selected every third character level) or as a class bonus feat, right? Wrong! Whenever I attempt to select the feat, I receive a console message, something akin to:

"Character is incapable of casting 9th level spells."
"Character has lost a level."

I didn't catch the message verbatim; however, the gist is correct in all respects. Could someone let me know just what the heck is going on here? Because I have a Wiz26 character that's dying to obtain the IMC feat, but can't get it due to some glitch - either on my end or on that of the code. Thanks again for your time.


October 20, 2010, 11:02:50 PM
Reply #1

Assuming I am reading the code correctly. If you don't have 9th level spells the or statement turns true, but the second ! operator makes it false. By that logic if you do have 9th level spells the if statement will tell you that you don't. Code is from the PRC 3.4 Beta.

Code: [Select]
int IgnoreMaterialComponents(object oPC)
{
    if(GetHasFeat(FEAT_IGNORE_MATERIALS, oPC))
    {
        if(!(!GetLocalInt(oPC, "PRC_ArcSpell9") || !GetLocalInt(oPC, "PRC_DivSpell9")))
        {
            FloatingTextStringOnCreature("You must be able to cast 9th level spells to take this feat.", oPC, FALSE);
            return FALSE;
        }
    }
    return TRUE;
}
« Last Edit: October 20, 2010, 11:06:12 PM by KenquinnTheInsaneOne »


October 21, 2010, 01:50:57 AM
Reply #2
  • Hero Member
  • *****
  • Posts: 1439
  • Karma: +27/-0
  • Gender: Male
    • View Profile

Quote from: KenquinnTheInsaneOne

Assuming I am reading the code correctly. If you don't have 9th level spells the or statement turns true, but the second ! operator makes it false. By that logic if you do have 9th level spells the if statement will tell you that you don't. Code is from the PRC 3.4 Beta.

Code: [Select]
int IgnoreMaterialComponents(object oPC)
{
    if(GetHasFeat(FEAT_IGNORE_MATERIALS, oPC))
    {
        if(!(!GetLocalInt(oPC, "PRC_ArcSpell9") || !GetLocalInt(oPC, "PRC_DivSpell9")))
        {
            FloatingTextStringOnCreature("You must be able to cast 9th level spells to take this feat.", oPC, FALSE);
            return FALSE;
        }
    }
    return TRUE;
}


If you have 9 lvl arcane spells GetLocalInt(oPC, "PRC_ArcSpell9") = 0 (same for divine).
So assuming that you have 9th lvl arcane and don't have 9th lvl divine spells:

GetLocalInt(oPC, "PRC_ArcSpell9") = 0
GetLocalInt(oPC, "PRC_DivSpell9") = 1
!GetLocalInt(oPC, "PRC_ArcSpell9")  = 1
!GetLocalInt(oPC, "PRC_DivSpell9")  = 0
(1 || 0) = 1
!(1 || 0)  = 0 - the code in if statement won't be executed. The logic is fine IMHO.


October 21, 2010, 12:29:03 PM
Reply #3

Shows my example of having the ability to cast no 9th level spells. The logic if you can cast at least divine or arcane spells pans out on my end.

Code: [Select]
GetLocalInt(oPC, "PRC_ArcSpell9") = 0
GetLocalInt(oPC, "PRC_DivSpell9") = 0
!GetLocalInt(oPC, "PRC_ArcSpell9") = 1
!GetLocalInt(oPC, "PRC_DivSpell9") = 1
(1 || 1) = 1
!(1 || 1) = 0 - The if statement would return false.


That was what I was thinking, but there is probable an issue with my logic.
« Last Edit: October 21, 2010, 02:32:07 PM by KenquinnTheInsaneOne »