• Please note: In an effort to ensure that all of our users feel welcome on our forums, we’ve updated our forum rules. You can review the updated rules here: http://forums.wolflair.com/showthread.php?t=5528.

    If a fellow Community member is not following the forum rules, please report the post by clicking the Report button (the red yield sign on the left) located on every post. This will notify the moderators directly. If you have any questions about these new rules, please contact support@wolflair.com.

    - The Lone Wolf Development Team

Making the Two World Trait work with two spells

Kalladar

Well-known member
I am trying to create a trait based on Two World Magic from Sargava, the Lost Colony. I have tried changing the 2nd Custom Expression to select another 0 level spell. That part looks like it should work correctly. When I try to modify the Eval Script, this is when I run into problems.

Since the class is no longer being selected by the 2nd Custom Expression, I tried to add the cCleric class into the script, but I evidently don't have the expression correct. Here is the old expression.


~if we haven't chosen anything yet, just get out now
doneif (field[usrChosen2].ischosen = 0)

~now that we've chosen a class, we can restrict the list of spells available
field[usrCandid1].text &= " & !(" & field[usrChosen2].chosen.tagids[sClass.?,"|"] & ")"

~if we haven't chosen anything yet, just get out now
doneif (field[usrChosen1].ischosen = 0)

doneif (tagis[Helper.FtDisable] <> 0)

~ If we are a spontaneous caster this will set the correct cantrip
perform field[usrChosen1].chosen.pulltags[ClsAllowSp.?]
perform field[usrChosen2].chosen.pushtags[ClsAllowSp.?]


This is what I have changed it to:


~if we haven't chosen anything yet, just get out now
doneif (field[usrChosen2].ischosen = 0)

~now that we've chosen a class, we can restrict the list of spells available
field[usrCandid1].text &= " & !(" & field [chosen.tagids[sClass.cCleric,"|"] & ")"
field[usrCandid2].text &= " & !(" & field [chosen.tagids[sClass.cCleric,"|"] & ")"



~if we haven't chosen anything yet, just get out now
doneif (field[usrChosen1].ischosen = 0)

doneif (tagis[Helper.FtDisable] <> 0)

~ If we are a spontaneous caster this will set the correct cantrip
perform field[usrChosen1].chosen.pulltags[ClsAllowSp.?]
perform field[usrChosen1].chosen.pushtags[ClsAllowSp.cCleric]

perform field[usrChosen2].chosen.pulltags[ClsAllowSp.?]
perform field[usrChosen2].chosen.pushtags[ClsAllowSp.cCleric]



The program doesn't like this modified expression. I have modified other scripts in the past, but I am missing something here.
 
Instead of building a tag expression based on the chosen class:

Code:
field[usrChosen2].chosen.tagids[sClass.?,"|"]
You know exactly what tag you want that to generate:

sClass.cHelpClr

So:

Code:
field[usrCandid1].text &= " & !(sClass.cHelpClr)"
Also, the last line - instead of pushing to the chosen class, you now know which class you want to push to:
Code:
perform hero.childfound[cHelpClr].pushtags[ClsAllowSp.?]
 
I modified the script, and it shows up in the traits area. The selection feature works on the trait, but the spells are not showing up on the cleric spell selection section. They just aren't there. Do I need all of the other statements ending the script or should it work as described. This is the way it looks now.


~if we haven't chosen anything yet, just get out now
doneif (field[usrChosen2].ischosen = 0)

~now that we've chosen a class, we can restrict the list of spells available
field[usrCandid1].text &= " & !(sClass.cHelpClr)"
field[usrCandid2].text &= " & !(sClass.cHelpClr)"

~if we haven't chosen anything yet, just get out now
doneif (field[usrChosen1].ischosen = 0)

doneif (tagis[Helper.FtDisable] <> 0)

~ If we are a spontaneous caster this will set the correct cantrip
perform hero.childfound[cHelpClr].pushtags[ClsAllowSp.?]
 
The trait allows me to select any 0 level spell and put it on the cleric spell list. I wasn't sure if I phrased that in the first posting.
 
My mistake. I didn't use the pulltags line when I modified it again. I have updated it and it works perfectly. Thank you for your assistance.
 
Back
Top