Senior Member
Volunteer Data File Contributor
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729
|
So I am adding a Racial Cust Special that acts just like a tool giving a +2 circumstance bonus to a small list of skills. So to make sure they cover the "tools" rules I copied the script from "Thieves Tools" to give myself a place to start.
Thieves Tools: Pre-Levels/10000 Code:
doneif (field[gIsEquip].value = 0) perform hero.childfound[skDisable].field[skToolMod].modify[+,2,"Mwk Thieves Tools"] I put the following script on my Racial Cust Special and I get an error: Pre-levels/10000 Code:
perform hero.childfound[skDisable].field[skToolMod].modify[+,2,"Shadow"] Code:
Attempt to use inconsistent operator for field adjustment with history tracking for field 'skToolMod' Location: 'eval' script for Component 'BaseSkill' (Eval Script '#8') near line 5 Image2.png But I need to figure out "why" or "what" is causing the BaseSkill component to toss the above error. Mathias/Aaron could you give any insights or thoughts on what is happening at line 5 that is causing the issue? 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. |
#1 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,213
|
This is a bug - if a field is set for "best" history tracking, which is the case for the skToolMod field, EVERY .modify[] that modifies that field must use the same modifier - +, -, * or /. The problem is that the script that says "we don't have any tools, therefore we get the -2 penalty" uses perform field[skToolMod].modify[-, 2, "No tools"].
So, because your script, at pre-levels/10000, used + on that field, the later use of - is incorrect. The long-term solution is that the "no tools" penalty should be applied in a different way. Alternatively, we need a history tracking option other than best (personally, I think "Best" is a trap, because you can't handle things like the Fate's Favored trait, which adds a bonus to something that, for all other purposes, uses the maximum). For a short-term solution, perform hero.assign[ToolsAvail.skDisable] before Post-Attr/10000, and the fact that tools are available for this skill will mean that the penalty is not applied, so there's not a - and a + applied to the same field. |
#2 |
Senior Member
Volunteer Data File Contributor
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729
|
Very interesting and good info. Thanks Mathias.
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. |
#3 |
|
|