View Single Post
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729

Old March 2nd, 2016, 10:34 AM
Quote:
Originally Posted by Sendric View Post
So I am attempting to assign a tag to a chosen thing, and am getting an error. In this case, the thing in question is a custom ability.

Here is the script I am using:

Code:
~ Add SpecSource tag
doneif (field[fChosen].ischosen = 0)

var source as string
source = hero.childfound[fShapeSouH].field[fChosen].chosen.idstring
source = "SpecSource." & source

perform field[fChosen].chosen.assignstr[source]
and here is the error:



Is this a bug or expected behavior? I have been able to do similar things in the past, so I'm not sure why this isn't working.
So the dropdown list you have is set to show "Things" and not "Picks". You can't modify a Thing only Pick. A "Thing" is something (ie feat, race, spell) that is in the HL database but is not Live on the character. Once chosen and added to the character it becomes a Pick and you can modify it with scripts.

I don't know what field[fChosen].chosen is accessing with out the custom expression. But in example if your download list was showing "Skills" and you set to "All Things" then you could see Knowledge skills in the dropdown list even though the Knowledge skill is not live or added to the skills tab. If you tried to modify that Knowledge skill you would get the 'Read only' error message above.

Hope that helps.

Hero Lab Resources:
Pathfinder - d20pfsrd and Pathfinder Pack Setup
3.5 D&D (d20) - Community Server Setup
5E D&D - Community Server Setup
Hero Lab Help - Hero Lab FAQ, Editor Tutorials and Videos, Editor & Scripting Resources.
Created by the community for the community
- Realm Works kickstarter backer (Alpha Wolf) and Beta tester.
- d20 HL package volunteer editor.
ShadowChemosh is offline   #17