• 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

PrC Requirements

Maquiscat

Member
OK so far I have figued out that any requirements for taking a PrC are inputed via Expr-Reqs. But the thing I have such a problem with is finding the tags to determine what I am entering.

For example the PrC I am entering has a requirement of Dodge. I used the following script:

#hasFeat[fDodge]

It also has the requirement of 3 ranks in Perform (Dance) so I used:

#skillranks[sPerfDanc] >=3

If I am correct, if I don't have the feat or the skill ranks then the PrC should be grayed out on the class list, correct? It is still showing as black.

I keep trying to search threads and the links in the sig lines from others who have helped me in the past. But I cannot find anything concrete. The worst part is that for some reason, when I try to load a PrC that has requirements as a copy, there are no scripts in Expr-Reqs for me to model after and determine how they work. Just point me to the right thread and I am willing to nuke it out.
 
A class has two parts the Class level and the class helper. Pre-req are located on the Class level not the class helper.

The class helper is added to a character once when selected and contains information like hit dice and number of skills.

The develop menu is your friend in finding tags and fields. FYI anything starting with a # is a macro (helper function).
 
Ok, across the sub tabs under Class the first four are: Archtype, Class, Class Level, and Class Special. Are you saying that PrC requirements go under the third tab, Class Level? And that the section no tab is the Class helper?
 
Ok, across the sub tabs under Class the first four are: Archtype, Class, Class Level, and Class Special. Are you saying that PrC requirements go under the third tab, Class Level? And that the section no tab is the Class helper?
Yeah sorry I was away from HL when I posted. "Class Helper" is really its name but the editor tab is "Class->Class".

When you select a class (ie Wizard) two Things become live on the character:

1) cHelpWiz - The Class Helper holds Hit Dice, Skill Points per level, etc.. Only ONE of these ever exists on the character.

2) cWizard - the Class Level holds hit points at that level, the favored class option. One per character class level exists on the character.

Sense cWizard is the Thing you are picking from in the list it needs to have the Pre-Req logic added to it. Sense cHelpWiz is never displayed in the UI adding pre-req logic to it does not help.

Hope that makes sense. :)
 
OK progress has been made, thank you. I managed to get the Skill requirements, the BAB requirements and 3 of the 4 Feat requirements. The only problem I am having now is determining if there is an or tag or something that will note that the character requires Weapon Focus on any slashing weapon. I am guessing that I would have to use the ID wType.S

So here was my fist guess:
hero.tagis[WepFocus.wType.S] <>0

based upon other Weapon Focus requirements. Didn't seem to work. I am guessing that is really for a single weapon check.

Doing some other digging, I found this thread and tried the following script:

var result as number
foreach pick in hero from BaseWep where "Broadcast.WepFocus" & "wType.S"
result += 1
nexteach

validif (result >= 1)

which resulted in the following error message:

Hero Lab was forced to stop compilation after the following errors were detected:

Syntax error in 'pre-requisite rule' script for Thing 'cDervish' on line 1
-> Invalid syntax for tag template

Not sure what I am missing. Oh and with that thread I found, was that person also importing Dervish from 3.5 or is there a PF Dervish as well? I only have the Core Rulebook and APG.
 
Code:
var result as number
foreach pick in hero from BaseWep where [B]"Broadcast.WepFocus" & "wType.S"[/B]
result += 1
nexteach

validif (result >= 1)
This is really close but the & symbol is outside the "" which when writing an expressing is bad.

This is correct.
Code:
var result as number
foreach pick in hero from BaseWep where [B]"Broadcast.WepFocus & wType.S"[/B]
result += 1
nexteach

validif (result >= 1)

Not sure what I am missing. Oh and with that thread I found, was that person also importing Dervish from 3.5 or is there a PF Dervish as well? I only have the Core Rulebook and APG.
No "class" but an bunch of archetypes and feats. Searching for the word Dervish on d20pfsrd shows all THIS! ;)
 
Sorry, life and work came up. I'm sure you know how that is.

Anyway, copied and pasted the corrected script into pre-reqs. I believe that is the correct place. And yes I am in the Class Level tab. It returned this when I hit test now:
Hero Lab was forced to stop compilation after the following errors were detected:

Syntax error in 'pre-requisite rule' script for Thing 'cDervish' on line 1
-> Invalid syntax for tag template

That would seem to be:
var result as number
Unless the variable name has to be isolated somehow, or there is a semi-colon missing (that used to always vex me with PHP) that looks like how many other languages define a variable. Am I missing something?
 
Let's back up, and make sure everything's set up right.

What is the book's text for the prereq you're trying to implement?

You're adding this in the Pre-Reqs button?

There are no other Pre-Reqs, Expro-reqs, or Pick-reqs on this class level? (I want to make sure it isn't reporting an error about another one of your prereqs, and the error message would say 'pre-requisite rule' for all three of those categories).
 
The Book is Complete Warrior, page 26, for the PrC requirements.

There are several Exper-reqs, seven to be exact so far, but I doubt that they are the cause because I inputed each one and then tested it before inputting the next. If I delete the script from Pre-reds, and test everything works fine.
 
The requirement (for the d20 3.5 Dervish) he's trying to code in PF is:
"Feat: Weapon Focus (any slashing melee weapon)"

The code that Mathias suggested in the thread referred to didn't have "var result as number", but that was for d20 not PF. (I don't know if it makes a difference)
 
Since the prereq you're copying will only work if the user has purchased a weapon of that type, here's a prereq to copy from that doesn't have that restriction:

Code:
var expr as string

        foreach thing in BaseWep where "wClass.TwoHanded & wCategory.Reach"
             expr = "WepFocus." & eachthing.idstring
             validif (hero.tagcountstr[expr] <> 0)
             nexteach

That's Weapon Focus (any two-handed weapon with reach)
 
Alright tried this:
var expr as string

foreach thing in BaseWep where "wType.S"
expr = "WepFocus." & eachthing.idstring
validif (hero.tagcountstr[expr] <> 0)
nexteach

I am guessing on wType.S as what replaces wClass.TwoHanded & wCategory.Reach. Didn't work. Also tried wCategory.Slash
I am still coming up with the exact same error message.

Hero Lab was forced to stop compilation after the following errors were detected:

Syntax error in 'pre-requisite rule' script for Thing 'cDervish' on line 1
-> Invalid syntax for tag template
 
I really think the error is coming from somewhere other than this script. Go ahead and attach the entire .user file, so we can take a look at everything, please.
 
Last edited:
The error is in one of your Expr-Reqs;
Code:
    <exprreq message="Weapon Focus feat with any Slashing weapon"><![CDATA[hero.tagis[WepFocus.wType.S] <>0]]></exprreq>

Tags are always two elements, separated by a period - this is three elements, with two periods.
 
Ah I seemed to have forgotten to delete that when shifting to the Pre-Reqs script.

With regards to the script in post #11, what am I using to show slashing weapon? Or better yet, where is a list of such things, so I can figure it out?
 
I was hoping for a more comprehensive list. For example, wType seems to deal with the weapons, but what are the words used for bludgeoning, slashing and piercing. For slashing, I could go .s or .slash or .slashing. Or where can I find the words that go with wClass or wCatagory? Or a list to show all the # functions such as #hasFeat and #skillRanks or the feat and skill names like fDodge and sPerfDanc? For dance I would never realize that the e was dropped. I consider myself lucky I found something that already had it.
 
Develop...Enable Data File Debugging. Then, right-click on a slashing weapon - what wType tag do you find there? Click on a one-handed weapon, what wClass tag do you find there?

For Ids of particular items, use the "Find Thing" button that's at the top right of all the script boxes in the editor.
 
Back
Top