View Single Post
Old 10-07-2013, 02:51 PM   #2
Armin
GCA Prime
 
Armin's Avatar
 
Join Date: Aug 2004
Location: Portland, OR
Default Re: Reaction block in a List format instead of String

Sorry I missed this earlier. The stuff below is talking just about charactersheet.gcs, and is in the Sub PrintReaction() routine.

Basically, right now, the code just grabs the trait's TagItem("bonuslist"), which is a single string of all the bonuses (or TagItem("conditionallist") which is the same for conditional bonuses), and then prints that.

If you want to print them line by line, you could grab the bonus text items one at a time, instead, and assemble the output from that. You'd use the item's BonusListItemsCount() function to see how many bonus items there are, and then use the BonusListItems(index) function to get each one. (Use Conditional instead of Bonus to get the conditional items.)

Alternatively, and probably easier, you could replace the ", " in the TagItem("bonuslist") text with a line break. I think using "\par " would do it since that section is using RTF. This method would use most of the code that's already there, just adding a new line for the substitution. It's slightly riskier because there may be naturally occurring commas in the text that aren't separating bonus items (but that's not common or likely).

If you don't know how to do any of the above, let me know and when I have some free time I'll see about modifying a version of the charactersheet.gcs for you.

Armin
__________________
Armin D. Sykes | Visit my GCA5 blog for updates and previews. | Get GURPS Character Assistant 5 now at Warehouse 23.
Armin is offline   Reply With Quote