• 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

Eval Script question....

BloodAngel099

Well-known member
I am trying to have a custom magic item with a +2 Profane bonus to Int and having the set max skill ranks for a skill to Knowledge: Planes and want it to add a custom language. I can't figure out what tags to use though. here is what I have so far (copied from Headband of Vast Intelligence).

Phase: Pre-Attributes Priority: 10000

~ Items which would add enhancement bonuses to attributes do not do so
~ when we are using the Auto Bonus Progression rules from Pathfinder Unchained.
doneif (hero.tagis[source.PUAutoB?] <> 0)

doneif (field[gIsEquip].value = 0)

#enhancementbonus[hero.child[aINT], 2]

~ add to our languages known
herofield[tLangsSpk].value += 1

Phase: Post-Levels Priority: 4000

~ Items which would add enhancement bonuses to attributes do not do so
~ when we are using the Auto Bonus Progression rules from Pathfinder Unchained.
doneif (hero.tagis[source.PUAutoB?] <> 0)

doneif (field[gIsEquip].value = 0)

~ now, we'll add item ranks to that skill equal to our HD
if (field[skKnowPlan].ischosen <> 0) then
field[skKnowPlan].chosen.field[skItem].value += herofield[tHitDice].value

endif
 
Last edited:
What is your timing?

And also, if you want to automatically grant skill ranks, you might want to use:

Code:
field[skKnowPlan].chosen.field[[B]skInnate[/B]].value += herofield[tHitDice].value

Instead of

Code:
field[skKnowPlan].chosen.field[[B]skItem[/B]].value += herofield[tHitDice].value

I believe that skItem is for adding a bonus, where skInnate is for adding unalterable ranks. Unless you are trying to add a bonus in which case, yeah.. use item. Or even better.

You should take a look at ShadowChemoshs' Concentration Skills in the community pack. They add ranks by default based on the level of the casting class. That might give you an idea in what direction to head.
 
skItem is the field for ranks you get when wearing an int-boosting items, it's not related to bonuses but rather "use the item ranks or the user ranks, whichever is greater".
 
I updated my original message with the Phase and Priority. I keep getting an error of non-existent field skKnowPlan. Is this not the correct field to use for the skill?
 
Um, unless things have changed, you don't want field[skKnowPlan] becauser there isn't one, you'd want hero.childfound[skKnowPlan]
 
Um, unless things have changed, you don't want field[skKnowPlan] becauser there isn't one, you'd want hero.childfound[skKnowPlan]

I tried what you suggested,
~ Items which would add enhancement bonuses to attributes do not do so
~ when we are using the Auto Bonus Progression rules from Pathfinder Unchained.
doneif (hero.tagis[source.PUAutoB?] <> 0)

doneif (field[gIsEquip].value = 0)

~ now, we'll add item ranks to that skill equal to our HD
hero.childfound[skKnowPlan].chosen.field[skItem].value += herofield[tHitDice].value

endif

I am now getting the error Script Reference in invalid under circumstances for line 9. Sorry I am not very good at the editor... :confused:
 
hero.childfound[skKnowPlan].field[skItem].value += herofield[tHitDice].value I think, untested but shoudl work
 
hero.childfound[skKnowPlan].field[skItem].value += herofield[tHitDice].value I think, untested but shoudl work

Thank you!!! I tried removing the "chosen." from there before, but I think i deleted the "." before field as well, must have been my problem. Worked like a charm this time!

Any ideas of how to add a specific language by chance?
 
Last edited:
Bloodangel, if you want a profane bonus to intelligence wouldn't you use#profanebonushero.child[aINT], 2] instead of #enhancementbonushero.child[aINT], 2]
as profane and enhancement are 2 separate types of bonuses and they stack with each other so you could also use a headband with your item.
 
Bloodangel, if you want a profane bonus to intelligence wouldn't you use#profanebonushero.child[aINT], 2] instead of #enhancementbonushero.child[aINT], 2]
as profane and enhancement are 2 separate types of bonuses and they stack with each other so you could also use a headband with your item.

Yea, I got the profane bonus fixed up, the biggest reason I was posting was the max ranks issue I was having, could not figure it out to save my life... but got it all working perfectly now.
 
Back
Top