In the script below I am trying to add Proficiency, Expertise, and Advantage to all Artisan Tools the character is carrying. It is part of a set of 3 scripts on a major Ring artifact.
Everything works fine except I'm at a loss on how to add Expertise (double proficiency).
Since the changes to Tools, it looks like Double Proficiency is done by adding the ProfTooDbl.? (where ? is the tag of the Tool - i.e.: gTooTinker for Tinker's Tools) directly to the hero.
What I am trying to do is extract the tag from each set of Tools the hero is carrying and assign ProfTooDb.{Tool tag} to the hero from within a foreach loop.
I'm at a loss on who to get the appropriate tag, append it to ProfTooDbl. and then assign it. Any help would be greatly appreciated.
Quote:
doneif (field[gIsEquip].value = 0)
doneif (field[gIsAttuned].value = 0)
var sTag as string
~ Grant Proficient & Expertise to All Tools carried and Advantage to All
~ Tools the Bearer is Proficient with.
foreach pick in hero from BaseEquip where "ToolCat.Artisan"
perform eachpick.assign[Proficienc.Tool]
perform eachpick.assign[Hide.Tool]
~sTag = eachpick.tagids[ProfTooDbl.?]
~perform hero.assign[ProfTooDbl.sTag]
nexteach
|