• 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

Profession skill and Tracker

Frodie

Well-known member
Any help with this script?

I want to get any ranks in a Profession skill to add one to the tracker

var wp as number
wp = 4
~search through our Profession skills.
foreach pick in hero from BaseSkill where "Helper.SkCatProf"

~ Add to our total charges.
field[trkMax].value += #skillbonus component.BaseSkill & [Helper.SkCatProf]
field[trkMax].value += #skillranks component.BaseSkill & [Helper.SkCatProf]
field[trkMax].value += wp
 
thanks it's skuser, but that realy isn't what I am looking for. I want to see if I can get all the profession skills to add 1 to the tracker for each rank
 
thanks it's skuser, but that realy isn't what I am looking for. I want to see if I can get all the profession skills to add 1 to the tracker for each rank

I'm confused.

If that is the ranks, then add it in your loop.

Or do you not want ranks?
 
To expand on what risner was saying about the field to look up, you'll want skUser + skInnate, since you want to count the pre-set skill ranks on a monster, in addition to the user-set skill ranks.
 
hum, IDK. I don't think we are are on the same page.
I want the profession skill (any of them) to add 1 to the tracker (wealth) for each 1 rank in the skill.
 
I want the profession skill (any of them) to add 1 to the tracker (wealth) for each 1 rank in the skill.

We are on the same page.


foreach pick in hero from BaseSkill where "Helper.SkCatProf"
field[trkMax].value += each.field[skUser]
nexteach

I didn't test this code, but that should be what you want. You may want to do the maximum between skUser & skInnate, as I think they do not stack?
 
Thank you for the help, but still not there yet. Some kind of error with the above script

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

Syntax error in 'eval' script for Thing 'trkShaHerW' (Eval Script '#1') on line 2
-> Invalid field syntax used"
 
field[trkMax].value += eachpick.field[skUser].value + eachpick.field[skInnate].value

risner, skUser and skInnate do stack, since when you add class levels to a monster that has pre-set skills, you want to be able to add more ranks to the skills that already have ranks.
 
Back
Top