Member
Join Date: Jul 2009
Location: Lewiston, ID.
Posts: 75
|
I'm designing a prestige class in which a cleric trades turn undead for the rage ability. I have added the rage ability but cannot figure out how to get rid of the turn undead ability once he selects the prestige class. Is there anyone able to help me with the scripting of this?
Thanks in advance |
#1 |
Senior Member
Join Date: Aug 2008
Location: Miamisburg, OH
Posts: 1,322
|
Quote:
Are you creating a brand new Prestige class using the panels, or have you copied the Cleric class and modifying it? |
|
#2 |
Member
Join Date: Jul 2009
Location: Lewiston, ID.
Posts: 75
|
Hey there, thanks for the response.
I will give an example. A character has several ranks in cleric and fulfills the requirements to take this prestige class. when he gains one level in this prestige class he gains the rage ability, but I want it to replace the turn undead of his original class and can't figure out how to remove that ability. I created this prestige class by copying the cleric base class, I removed the cleric abilities from the new prestige class and added other abilities, rage included. What I can't figure out how to do is, once the character takes the prestige class, the rage ability is suppose to replace the turn undead of his original cleric class. I hope I'm being clear here because it still looks a little muddled written down. Thanks again for any help |
#3 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,213
|
Wait 24h - disabling class specials has been added to the latest release.
|
#4 |
Member
Join Date: Jul 2009
Location: Lewiston, ID.
Posts: 75
|
Ok, I have the new update and have created a variant that removes the turn undead from the cleric specials but I can not figure out how to link it to my prestige class to that it takes effect when the prestige class is taken.
Any thoughts? |
#5 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,213
|
Sorry I didn't have a chance to follow up on this question before now. Actually, you can have the prestige class directly disable the special, rather than using a variant class that disables it. I'll basically be showing you how to recreate in a script what the variant class does in the background.
If this disabling is attached to a specific class special on the prestige class, put the script there, or you can put it on the class tab of the prestige class (rather than the class level). Make your script's timing First, 10000. Here's the script: Code:
var searchexpr as string searchexpr = "component.BaseSpec & SpecSource.cHelpClr & (SpcReplace.xTurning | SpcReplace.cClrUndead)" foreach pick in hero where searchexpr perform eachpick.assign[Helper.SpcReplace] perform eachpick.assign[Helper.SpcDisable] perform eachpick.delete[Helper.ShowSpec] nexteach endif First, it creates an expression, that will match any specials that are attached by the cleric class and that have the unique IDs "xTurning" or "cClrUndead" - which are the two pieces of turn undead (cClrUndead is the part seen on the cleric's list of class specials, xTurning appears in the specials tab, and is added by Paladins, too). It then searches through everything on the hero, and each time it finds something that matches all the criteria that were set up, it tells the special that it's been replaced (so that if you add this prestige class and a variant class that also replaces turn undead a validation error will be shown), then it tells the special that it's been disabled, and finally removes the tag that allows the special to be shown on the summary list, special tab, and printout. |
#6 |
Member
Join Date: Jul 2009
Location: Lewiston, ID.
Posts: 75
|
Thanks for the reply. I feel I am close to having my prestige class prefected. No this will only be a cleric prestige class so no need to add anything for other classes.
Only one problem, when I test the script the endif statement gives me an error but without it the turning is not removed. If an "if" goes in there somewhere I no idea where. Once again thank you so much for the help, it is greatly apreciated. |
#7 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,213
|
Whoops - my mistake - the endif on the last line is a holdover from the full script, which checks to make sure that there are replacements to make before running all that. Just delete the endif line.
The turn undead is not disabled if the script is run without the endif? It will still be present on the Cleric's list of special abilities, but will be grayed out, and the summary text will say that it is disabled. |
#8 |
Member
Join Date: Jul 2009
Location: Lewiston, ID.
Posts: 75
|
Sorry to keep bothering you about this. I must seem a great pain in the butt. but that being said, I just can't seem to get the thing to work. I've tried putting it in Eval Scripts of the class, of the class special ability, and making it its own special ability and bootstrapping it to the prestige class. Nothing seems to gray out the turn undead ability when I add the prestige class. I am at a loss.
sorry to keep hounding |
#9 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,213
|
It's not your fault, it's mine. I hadn't actually tested what I was telling you to do, and it turns out it doesn't work quite as intended. If you click on the big oval "i" on the cleric tab, your script should be correctly disabling the copy of turn undead that lives there (cClrUndead), but it turns out it doesn't properly disable the copy that ends up in the specials list (xTurning).
When writing the special ability disabling code, I never tested a variant class that disables turn undead, so I ddin't come across this. The solution is to modify cClrUndead, so that its script doesn't run when it's disabled. To do so, in the editor (you might as well do this in the same file as your prestige class), go to class specials, and press "New (Copy)". Now select the "Turn / Rebuke Undead (cClrUndead)" special. Give your copy a new unique ID (like cClrUndea1), and in the "replaces thing ID" field on the right-hand side, enter the unique ID of what you're replacing (cClrUndead). Now to edit the script. Place the following code at the top of the script - it should be the first instruction executed: Code:
~ If we're not shown, just get out now doneif (tagis[Helper.SpcDisable] <> 0) I've made the same change to cClrUndead in the copy on our server, but I'm not sure when a bug fix update will actually be published, since that's the first fix since the release earlier this week. Once the update is published, the replacement Turn / Rebuke Undead thing will be redundant, but it won't break anything, either, so it can be deleted at your convenience. |
#10 |
|
|