Ok, I had something that seemed to work yesterday, but it doesn't today so now I'm stumped again.
I took some scripts from the Mystic that someone did. The Mystic uses domains like a Cleric does, but Psionic Mantles don't work exactly the same way as domains. Instead of granting a bonus spell (power), Mantle powers are the only powers the character can choose from. Even so, I'm trying to handle things in a similar fashion since I don't really have any other ideas. There seems to be multiple steps involved. The class I'm working on is called Ardent.
When creating the custom ability (in this case, Chaos Mantle), I put in the following Eval Script:
Then added this as one of the Eval Rules:
It's also unclear to me if I need to specify the class when I create the power. For example, when I create the power, do I need to set "Power Class" to Ardent? When I do that, the powers show up in the classes available powers list before selecting the mantle, so I'm guessing that's wrong. It's weird that yesterday I did this and the power was there, but grayed out until I selected the mantle. Today, it's no longer grayed out. Apparently HL changed its mind about how to handle my craptastic coding.
Anyway, what I ultimately need to be able to do is add certain powers to the available powers list after someone has selected a mantle. Any help would be greatly appreciated.
I took some scripts from the Mystic that someone did. The Mystic uses domains like a Cleric does, but Psionic Mantles don't work exactly the same way as domains. Instead of granting a bonus spell (power), Mantle powers are the only powers the character can choose from. Even so, I'm trying to handle things in a similar fashion since I don't really have any other ideas. There seems to be multiple steps involved. The class I'm working on is called Ardent.
When creating the custom ability (in this case, Chaos Mantle), I put in the following Eval Script:
Code:
Final Phase, 10000
perform delete[Helper.ShowSpec]
~ Check through all our spell levels, if we can cast spells of that level, add 1 for the bonus spell from our domain. This will be enforced through an eval rule.
if (hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[1] <> 0) then
hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[1] += 1
endif
if (hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[2] <> 0) then
hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[2] += 1
endif
if (hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[3] <> 0) then
hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[3] += 1
endif
if (hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[4] <> 0) then
hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[4] += 1
endif
if (hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[5] <> 0) then
hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[5] += 1
endif
if (hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[6] <> 0) then
hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[6] += 1
endif
if (hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[7] <> 0) then
hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[7] += 1
endif
if (hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[8] <> 0) then
hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[8] += 1
endif
if (hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[9] <> 0) then
hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[9] += 1
endif
Then added this as one of the Eval Rules:
Code:
Validation Phase; 20000
validif (hero.childfound[cHelpArd].field[cKnowMax].arrayvalue[1] = 0)
validif (hero.pickexists[sCha20000] <> 0)
It's also unclear to me if I need to specify the class when I create the power. For example, when I create the power, do I need to set "Power Class" to Ardent? When I do that, the powers show up in the classes available powers list before selecting the mantle, so I'm guessing that's wrong. It's weird that yesterday I did this and the power was there, but grayed out until I selected the mantle. Today, it's no longer grayed out. Apparently HL changed its mind about how to handle my craptastic coding.
Anyway, what I ultimately need to be able to do is add certain powers to the available powers list after someone has selected a mantle. Any help would be greatly appreciated.