Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - Pathfinder Roleplaying Game


Thread Tools Display Modes
Senior Member
Volunteer Data File Contributor
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,590

Old February 20th, 2019, 02:10 PM
Putting BonusFor.? tags on the hero does not make any sense to me. How would HL know which class or classes the tag was meant for. I am pretty sure you should be assiging the BonusFor.? tag to the class itself.

doneif (hero.tagis[source.WiSRules] + hero.tagis[source.WiSWeapons] = 0)

~ We're an NPC, and subject to feat taxes, so we're done
doneif (hero.tagis[WiSRules.PayFeatTax] <> 0)

~ Check if we're a Tempered Champion
doneif (hero.tagis[ClassVary.arPalTmpCh] = 0)

perform hero.childfound[arPalTmpCh].linkage[varies].assign[BonusFor.wsTempChamp]
Also instead of even using "BonusFor.?" each feat makes a tag called fInclude.? where ? is the Unique ID of the feat. So if I wanted to allow the choice of the Dodge feat as a bonus feat to a class I could just assign the tag fInclude.fDodge to the class.

Hero Lab Resources:
Pathfinder - d20pfsrd and Pathfinder Pack Setup
3.5 D&D (d20) - Community Server Setup
5E D&D - Community Server Setup
Hero Lab Help - Hero Lab FAQ, Editor Tutorials and Videos, Editor & Scripting Resources.
Created by the community for the community
- Realm Works kickstarter backer (Alpha Wolf) and Beta tester.
- d20 HL package volunteer editor.
ShadowChemosh is online now   #101 Reply With Quote
Senior Member
Join Date: May 2013
Posts: 172

Old February 20th, 2019, 08:37 PM
Well, I was looking at the scripting in the custom ability that defines the two-weapon fighting for rangers, where it said this:

      ~ at level 6, we add more bonus feats available (we add them to ourself,
      ~ and then at First/1500, all fInclude tags are forwarded to the class)
      if (levels >= 6) then
        perform assign[BonusFor.RgrTwoW6]
I guess my misunderstanding arose from interpreting the comment "we add them to ourself" to mean the hero. I take it that it actually refers to the custom ability, which is attached to the class?

Even after working on it for a couple of years, I have to confess that my understanding of Hero Lab's data model is shaky at best. Most of the time I just go look up something that does something vaguely like what I'm trying to do and try to figure out how it does it. In this case, that didn't work out so well.

Thanks for the code, Shadow -- it worked very nicely. I still need to figure out how to mark them as bonus feats so they ignore pre-reqs like the fighter levels that the paladin doesn't have, but otherwise it's working.

EDIT: Well, I've gotten it to quit complaining about the missing fighter levels by adding this code to the mechanic:

if (#hasfeat[fwsWepFoc] <> 0) then
perform hero.child[fwsWepFoc].assign[thing.skipprereq]

if (#hasfeat[fwsGrWFoc] <> 0) then
perform hero.child[fwsGrWFoc].assign[thing.skipprereq]

if (#hasfeat[fwsWepSpec] <> 0) then
perform hero.child[fwsWepSpec].assign[thing.skipprereq]

if (#hasfeat[fwsGrWepSp] <> 0) then
perform hero.child[fwsGrWepSp].assign[thing.skipprereq]
That prevents errors after the feat has been chosen. But it still greys them out in the list of feats. I'm a little surprised that the "counts as fighter levels" bit wasn't implemented in the archetype. All of the variant feats in World is Square that require fighter levels are set up to call #featprereqlevelcount[Fighter] -- I guess I thought there'd be a select box or an eval script or similar that says "Levels of this count as fighter" that that macro would pick up on. But I guess not.

Oh well. If I want to make those feats appear to be valid choices again, do I need to tag the hero as being fighter level X? Or assign some tag to the feats themselves before they're selected? I'm not sure how to get at a feat before it's been picked ...

Last edited by wdmartin; February 20th, 2019 at 09:34 PM.
wdmartin is offline   #102 Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT -8. The time now is 08:57 PM.

Powered by vBulletin® - Copyright ©2000 - 2019, vBulletin Solutions, Inc.
wolflair.com copyright ©1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.