Can you find any code anywhere that deals with changing the value of a field?
Can you figure out how to delete an existing tag value and add a new tag value?
Think in terms of abilities in Pathfinder that alter how something else functions - that's the sort of ability that will be altering the fields and tags of other things.
Since I can't think of a good example to lead you to in order to give you this, here's how to reach the race, no matter which race it is:
Code:
perform hero.findchild[Race].setfocus
doneif (state.isfocus = 0)
And once the focus has been established, you can use
to get there, instead of the hero.child[XXXXX]. you may see in other places.