View Single Post
Mediator9292
Member
 
Join Date: Apr 2018
Location: New York
Posts: 45

Old August 24th, 2023, 03:12 PM
Alright so I think I've got a general system set up for how to build this, but I'm running into some errors and I'm not sure how to fix it.
Below is my code and selections for the first test Runestone, which is supposed to grant the Flaming property:

Can be equipped (no slot)
Show in Activated Abilities list
Activation Name: Slotted
Custom Expression: component.BaseMagicI & (component.BaseArmor | component.BaseWep)
All picks on Hero

Runs at Pre-Levels 9000
Quote:
if (field[gIsEquip].value <> 0) then
if (field[abilActive].value <> 0) then
doneif (field[usrChosen1].ischosen = 0)
if (parent.tagis[component.BaseWep] <> 0) then
#extradamwithavg[parent," plus 1d6 fire",field[thingname].text,"3.5"]
else
foreach pick in hero from BaseWep where container.child[gCustMagic].field[gWeapExpr].text
#extradamwithavg[eachpick," plus 1d6 fire",field[thingname].text,"3.5"]
nexteach
endif
endif
endif
All seems to go well from 1. selecting the magic weapon, 2. equipping the runestone, and then when I Slot it in the In-Play tab, I get the following error:
Attempt to access non-existent parent pick for a top-level container from script
- - -
Attempt to access non-existent child pick 'gCustMagic' from script
- - -

Any advice or ideas on how to fix this?
Mediator9292 is offline   #3 Reply With Quote