ShadowChemosh
June 20th, 2010, 09:37 AM
I was going back to older .user files and updating them with the latest changes to HL. Things like using BonTrait for traits and such. A trait from Tadlor Echoes of Glory is Precocious Spellcaster. Here is the benefit: Select one cantrip and one 1st-level spell; when you cast these spells, they function at one caster level higher than your actual caster level.
I thought great I will update it to the use the new field[sCL] that was added. I am running into some errors though trying to use this.
I have a custom expression "component.BaseSpell&sLevel.0" so a single cantrip can be picked.
Here is one of the scripts I tried.
~Pre-levels 5,000
~set our focus to the selected pick
call fTargetFoc
doneif (state.isfocus = 0)
focus.field[sCL].value += 1
Here is the error message I get when I choose Acid Splash for a Sorcerer that did have Acid Splash added under the Sorcerer tab.
Attempt to access pick information or behaviors for read-only thing 'spAcidSpl0'
Location: Procedure 'fTargetFoc' near line 6
So I know another way to pick up a chosen field so I tried that next. Here is that script:
~Pre-levels 5,000
if (field[usrChosen1].ischosen <> 0) then
field[usrChosen1].chosen.field[sCL].value += 1
endif
And here is its error message:
Attempt to assign field value with no pick context.
What I am missing or doing wrong when trying to use this new field[sCL]. I also tried just setting the Acid Splash spell using its ThingId and that worked correctly. I then tried to find an existing thing like (Gifted Adept) which does basically the same thing, but it as of yet has no scripts.
Any help would be much appreciated.
I thought great I will update it to the use the new field[sCL] that was added. I am running into some errors though trying to use this.
I have a custom expression "component.BaseSpell&sLevel.0" so a single cantrip can be picked.
Here is one of the scripts I tried.
~Pre-levels 5,000
~set our focus to the selected pick
call fTargetFoc
doneif (state.isfocus = 0)
focus.field[sCL].value += 1
Here is the error message I get when I choose Acid Splash for a Sorcerer that did have Acid Splash added under the Sorcerer tab.
Attempt to access pick information or behaviors for read-only thing 'spAcidSpl0'
Location: Procedure 'fTargetFoc' near line 6
So I know another way to pick up a chosen field so I tried that next. Here is that script:
~Pre-levels 5,000
if (field[usrChosen1].ischosen <> 0) then
field[usrChosen1].chosen.field[sCL].value += 1
endif
And here is its error message:
Attempt to assign field value with no pick context.
What I am missing or doing wrong when trying to use this new field[sCL]. I also tried just setting the Acid Splash spell using its ThingId and that worked correctly. I then tried to find an existing thing like (Gifted Adept) which does basically the same thing, but it as of yet has no scripts.
Any help would be much appreciated.