Author Archives: Armin

A hodgepodge of bits and templates (b156)

b156

The image caption sheet option that I kludged together last build is now a bit smarter in sizing the image, allows larger images, and now supports aligning left, top, right, or bottom.

The Sheet Options dialog will now open with the currently active sheet profile’s options selected and loaded.

More type conversions.

The expanded $if() function had a bug if you used ‘elseif’. Fixed it.

Added some error traps for some more situations with template command handling.

Adds() and Creates() should be slightly less stupid now about empty items as a result of extra commas.

I’ve added the addsorincreases() tag for templates. It works somewhat like adds() or sets(), but actually looks first for the trait on the character, and if found, *increases* it by the set value; if not found, GCA tries to add the trait to the character at the given value like adds(). This has aliases: addorincrease(), addsorsets(), and addorset() because I couldn’t settle on the name. This works inside triggers() or is processed in the standard tag list after adds(). NOTE: Given that known attributes always exist, you’d use this with attributes as ‘increase by this amount’, so to add 1 to ST you’d use ST:ST=1.

Added the message() tag, which works like the #Message directive, but in a tag. Works in triggers() or is processed in the standard tag list last, just before cleaning up directives, before item calculations begin on newly created items. This is primarily meant for use in triggers() since it can only handle a single message, but it works if you just need one at the end.

Added the new directive #BuildLibraryItemList. This works exactly the same as the #BuildCharItemList, except it operates on the character’s Library items to select from to build the list. Bear in mind that nothing you tag to character items will be the same in the Library items: that’s just book data as loaded from the files. (I keep thinking that I already added this directive years ago, and keep finding that it’s not there, so now it definitely is.)

Addressed some issues with the money fields in the Campaign Log dialog.

* SelectX()/Select()

Random selections in Select dialogs for templates were not working correctly if Refuse Dupes was turned off for the item types in question. That has now been fixed.

Fixed an icon in Select dialogs to match the explainer.

The special case variables for previous SelectX() selections are now used in a few more places, so you can now use them in the conditional() and text() tags.

You can now use recommended() as one of the tags of the SelectX() to recommend traits to the user. This should specify one or more traits in a list, with prefixes, and enclosed in quotes or braces when necessary. If any of the traits specified here are found in the library trait list provided to the user, then they will be marked with a ‘favorites’ gold star on the right side of the listing, indicating their recommended status.

The colors on the dialog should be fixed now.

* Plugins

I changed the names of a bunch of routines in GCACharacter related to directives, in order to make them more consistent across functions. These were all routines that nobody but me is likely to use, but they are Public, so the change may affect the profile of the interface, which may make compiled plugins no longer compatible. As a result, you may need to change your Reference to GCA5Engine to this new version in order to get your plugin to compile.

* Data Files (Released 2021 September 19)

Dungeon Fantasy RPG.gdf: All cases of ‘Shield Wall Training’ changed to ‘Shield-Wall Training’

* Data Files (Released 2021 September 15)

Dungeon Fantasy RPG.gdf: All cases of ‘Armoury’ changed to ‘Armory’

* Data Files (Released 2021 September 2)

GURPS Action 1 – Heroes.gdf: Updated the Assassin, Medic, Wheel Man, and Wire Rat templates.
GURPS Basic Set 4th Ed.–Characters.gdf: Just added units() to Basic Lift.
GURPS Ultra-Tech 4e.gdf: Fixed the Encoding=UTF-8 at the top of the file and fixed the Android (Ultra-Tech) template.

A bit of an event (b155)

b155

Character event handlers were being set in a routine that worked fine for a single character load, but only worked for the last one loaded when loading them in a batch, such as a party load or multiple characters selected in Open. These handlers are now assigned in the routine that handles the post-load processing in the main UI form, where they should have been all along.

There is now a Favorite button on the Sheet View toolbar which allows you to set the current sheet profile as your favorite for the current character, which sets it as the default print sheet without having to go into Options to do that.

I have finally added the settings to format equipment costs and weights to the Options dialog.

I have once again gone through and converted a lot of implicit type conversions to explicit ones. In some cases, this may have unexpected consequences if I did things slightly differently than the implicit conversion did.

I shoehorned in a new version of a sheet option, which is a caption that supports displaying an image. This is currently handled automatically by GCA when you include an “[image]” code as the very first text in the UserPrompt of a Caption control. That triggers GCA to use the new image caption instead of the standard one. You can currently only align the image to the top or the left, and you do that within the [image] marker, such as [image align=top] or [image align=left]. The image is limited to 150px tall when at the top, and 250px wide when on the left, and will zoom inside the picture area to fit those limits. When on the left, the image is allowed a maximum scaled height of 300 px, and will scale down the allowed width if necessary to meet that cap. (As a side-effect of this being a new control, it makes use of my BBCode label, so the caption also supports limited bbcode, such as [b][/b] for bold and [i][/i] for italic.)

Reverted the change in b151 where UnassignedItemsAsLoadout() would return the loadout as fully functional. That wasn’t actually fully correct, and making it so was overkill for the primary purpose of UnassignedItemsAsLoadout(), which is just to see what items are not included elsewhere. The procedure that does do this is now a new function called UnassignedItemsAsLoadoutWithProtection(), which creates a complete loadout with the default body and hit table and fully calculated protection values.

I fixed some design issues with the Attack Modes box in Unified. It should refresh and update much more smoothly now. I also added an option to show/not show the symbol icons for the traits in the box.

* Official Character Sheet (posted via Updater on 2021 August 24)

Included an adjustment to fully activate and calculate the protection values of an All Unassigned Items loadout when we want to actually print those protection values.

A bit of regional concern (b154)

b154

When calculating the weight capacity for items, if weightcapacityunits() is not specified, it now defaults to the item’s units() instead of ‘lb’.

* Region & Culture Issues

One of the Beta Preview testers found what looks like an insidious issue related to regional settings, but one not dependent upon the decimal separator, which so many of our regional settings issues have been related to in the past.

I have now tracked this down to one of the library routines, IsNumeric(), that I use initially in the Solver to ensure that we simply return a numeric value as the result, without having to take any additional steps. IsNumeric() doesn’t work “properly” in some regions; that is, it decides something isn’t numeric based on regional settings but doesn’t seem to take into account the decimal and thousands separators individually.

I have two options: 1) write my own IsNumeric(); 2) apply a culture to GCA so that it always runs with the decimal point as a period and using commas for thousands separators.

Option (2) is the route I’ve taken, since I already basically require that to be the case. I’ve currently set it to keep the user’s default culture settings, and only force the issue with the separators. This means that other settings, such as date formats, will stay consistent for the user.

* Official Character Sheet (posted via Updater on 2021 August 8)

Added support for languages using levelnames() with | separators for split spoken|written levelnames.

Cleaned up language display to not include the level in the language name, since there’s a whole column for the level already.

* GURPS Basic Set 4th Ed.–Characters.gdf (posted via Updater on 2021 August 8)

[LANGUAGES]
Language – using literacy levels, 2/4
Language – Native – using literacy levels, 2/4
Added both of these to include support for languages using levelnames() with | separators for split spoken|written levelnames.
This was due to some users not liking the fact that written languages used literacy levels, but the full languages used the broken and accented terms.

A bit of weight (b153)

b153

* Weight

GCA will now attempt to automatically convert equipment weights to or from metric. This uses the units() tag to try and determine if the current item is metric, and if the character is set to metric (the Metric attribute score is 1). If there is no units() tag, it’s assumed to be ‘lb’. If the item’s units don’t match the character setting, GCA will try to convert the weight to the preferred units. (Default conversion is done using the standard GURPS conversions, which are not precise. If you want better precision for metric values use Metric versions of the data files.)

The units() tag may specify two different units separated by a |, with standard units first and metric second, such as units(kg|lb). If this is the case for an equipment item (and I’m not aware of any that do this), then GCA will not try to convert that item, since specifying both types of units already suggests that the item is aware of metric support and handling it automatically.

Notes:

1) Setting the character to metric will always affect some labels in some portions of the program (such as loadout weight labels), or on some sheets, even if the values may not be correctly calculated as metric due to the data not actually being written for metric;

2) GCA won’t auto-recalculate when you change the Metric attribute, so you must do a Recalc All to see the changes.

GCA will also try to convert weight capacity if an item has it. This requires the new weightcapacityunits() tag, and if that doesn’t exist, it is assumed to be ‘lb’.

GCA now adds/manages the charweightcapacity() tag for items that have a weightcapacity(). This is the same as the weightcapacity(), unless GCA is converting weights due a difference in the Metric setting and provided units, in which case it will be the converted value. GCA likewise manages the new charweightcapacityunits() tag, which should be the units the capacity is measured in, and will be the same as any weightcapacityunits() tag unless conversion is performed.

GCA will not attempt to convert weight capacity if it is not already converting weight.

* Miscellaneous

Updated drawing code for capacity gauges to use charweightcapacity().

Fixed an error in drawing the capacity gauges that would cause them to disappear when items were over capacity, instead of turning them red.

Character lists in Unified and Classic should now use the charunits() tag for labeling the units where applicable for weights.

These tags were specified in the GCA5.XSD as being saved in the ‘ref’ section of GCATrait, but GCA was not saving them there until now: “weightcapacity”, “weightcapacitylevel”, “overweightcapacity”, “overweightcapacityby”, “countcapacity”, “countcapacitylevel”, “overcountcapacity”, “overcountcapacityby”

* GCA5.XSD

These tags have been added to the ‘ref’ section of GCATrait: “charunits”, “weightcapacityunits”, “charweightcapacity”, “charweightcapacityunits”

Preset bits (b152)

b152

When modifiers are created from book data, having a group() tag in the modifier’s tag data was overriding the assignment of the group based on the subhead. When the group() tag was incorrect, this created a problem. Now, the subhead is always used to assign the group(). If Verbose logging is enabled while loading books, GCA will log a complaint when this happens.

It should now be possible to drag-and-drop an image onto the Protection dialog to set the body image for the current loadout.

Made a small change in the version testing of book files so that GCA now assumes an unreadable or non-existent version specification in a data file means that the file is older than the program version, instead of newer.

* Sheet Options – Presets

Sheet Options now supports preset options that can be set from a new Available Presets button. This button will appear only if preset options are found for the current sheet.

Sheet authors can include preset options by including saved profiles in a file called ‘presets.prefs’ in their plugin folder. GCA will check for that file when the user changes sheets in the Sheet Options dialog and gather up all the profiles in that file that are for the selected sheet.

When the user clicks the Available Presets button, they’ll get a dialog showing the available presets. If they select one, those settings will then be imported into the currently active profile.

The sheet plugin will be asked to upgrade options before the import, same as when the user uses the Import feature.

* Sheet Options – Checkboxes

Those sheet options that display a list of checkboxes for the user to check now have buttons to check all the boxes or to clear all the boxes.

* Data Files (posted via Updater on 2021 August 1)

GURPS Magic 4e.gdf updated modifiers for “One College Only (%College%)” and “One College Only (%College%)” to remove the group() tags.

* Official Character Sheet (posted via Updater on 2021 July 28)

You can now specify the image to use in the GURPS logo slot (upper left corner) of the sheet. You should be able to use most PNG, JPG, or BMP images. Note that the image will be sized to fit a space of 1.75 x 0.5625 (1 3/4 x 9/16) inches on the front, and a slightly smaller 1.625 x 0.5 (1 5/8 x 1/2) inches on the back. If your image isn’t exactly the right dimensions, it will be aligned to the top of the space, centered horizontally.

Added an option to include Extra Roll info in the trait lists, selected by list type. This is now Yes for all lists by default. This includes Roll To: text as a smaller-text additional line under the trait item, similar to how bonuses or notes are printed.

Added an option to include the Bonus and/or Conditional bonus text for traits, selected by list type. These are now Yes for all lists by default. The sheet was already printing these, but now you can turn that off.

Added an optional Encumbrance, Move, Dodge table to use in place of the default one. This alternate table is of the same design as the Encumbrance & Move box used on the Unified and Classic views, so it will show the movement rates for whatever active movement modes the character has. This option is No by default.

Smoothed out some issues with the printing of the Block values on the front page when using shields from the active loadout.

Now, for traits, only the bonus/conditional text is printed in the user-specified bonus text color. Description and extra roll text is printed in the sheet color, while user note text is printed in the user text color.

Added an option to print DR by hit location in the DR box. It will increase the size of the box by stealing space from Languages above and TL/Cultural Familiarities to the right, but the text will still be small. This is No by default.

The Feats of Strength box now includes labels for the weight and distance units.

Nothing but sheet bits

* Official Character Sheet

You can now specify the image to use in the GURPS logo slot (upper left corner) of the sheet. You should be able to use most PNG, JPG, or BMP images. Note that the image will be sized to fit a space of 1.75 x 0.5625 (1 3/4 x 9/16) inches on the front, and a slightly smaller 1.625 x 0.5 (1 5/8 x 1/2) inches on the back. If your image isn’t exactly the right dimensions, it will be aligned to the top of the space, centered horizontally.

Added an option to include Extra Roll info in the trait lists, selected by list type. This is now Yes for all lists by default. This includes Roll To: text as a smaller-text additional line under the trait item, similar to how bonuses or notes are printed.

Added an option to include the Bonus and/or Conditional bonus text for traits, selected by list type. These are now Yes for all lists by default. The sheet was already printing these, but now you can turn that off.

Added an optional Encumbrance, Move, Dodge table to use in place of the default one. This alternate table is of the same design as the Encumbrance & Move box used on the Unified and Classic views, so it will show the movement rates for whatever active movement modes the character has. This option is No by default.

Smoothed out some issues with the printing of the Block values on the front page when using shields from the active loadout.

Now, for traits, only the bonus/conditional text is printed in the user-specified bonus text color. Description and extra roll text is printed in the sheet color, while user note text is printed in the user text color.

Added an option to print DR by hit location in the DR box. It will increase the size of the box by stealing space from Languages above and TL/Cultural Familiarities to the right, but the text will still be small. This is No by default.

The Feats of Strength box now includes labels for the weight and distance units.

A bit more sheet (b151)

b151

Equipment lists in Unified and Classic always showed ‘lbs’ for equipment weights, even when the user had toggled the Metric stat. That is now fixed.

Added a missing word to the Protection Options explainer in the Protection dialog.

The UnassignedItemsAsLoadout() routine in the LoadOutManager didn’t return the All Unassigned Items loadout as a fully functional, ready to use loadout. Now it does.

* Official Character Sheet

Added an option to show a column for min ST on the Hand Weapons table. This is set to Yes by default and the column is labeled “ST”.

Added an option to include a Level and Parry score, instead of the Parry Adjustment, to the Hand Weapons table. This is now Yes by default, and the column is labeled “Lvl (Pry)”.

Added an option to include a Level column on the Ranged Weapons table. This is now Yes by default, and the column is labeled “Lvl”.

Added an option to have the “Lvl” and “Lvl (Pry)” columns printed as the first column after the name of the weapon. This is Yes by default.

Added options to highlight the new “Lvl” and “Lvl (Pry)” columns with a different background color and to set the desired color for the column. The default color is light sky blue but the default is to not highlight the columns.

Added an option to have shields in the Weapon tables print their Block score in the “(Pry)” slot instead of the usual ‘No’ for “(Pry)” since they block instead.

Added an option for the sheet to get the active shield (or two) from the current loadout, get the block score from that, and print that as the Block value on the first page. This is now the default behavior. Also added an option to print a diagram of the coverage arc for that shield next to the block value, which is also the default behavior.

Added an option to include a reminder message about adding DB to active defenses, which will appear under the Encumbrance/Move/Dodge and Parry/Block sections. This option is No by default.

Teensiest of bits (b150)

b150

Fixed an issue where the points bar didn’t always change some values to red or black correctly.

When GCA was checking prereqs, and a prereq was an attribute, GCA was attempting to set a value incorrectly, and that crashed the program. That is now fixed.

* Official Character Sheet

Added some optional blocks that can print additional attribute information: Feats of Strength, Perception, Checks (consciousness, death, fright), and additional attributes (other attributes not displayed elsewhere). Checks and Perception print in the right column above Skills, while Feats of Strength and Additional Attributes print in the left column above Advantages.

GCA Beta Preview, Release 2, Now Available

The second release of the GURPS Character Assistant 5 Beta Preview is now available.

The first release was announced in this post, which has more details.

This release fixes all the reported bugs so far, and includes some updates and other fixes, as detailed in the various build notes posted on this blog.

You can find the installer available for download here:

https://www.sjgames.com/gurps/characterassistant/gca5beta/gca5betapreview.zip

If you want to validate the ZIP after download, there is a PAR2 file here:

https://www.sjgames.com/gurps/characterassistant/gca5beta/gca5betapreview.zip.par2

The GCA5 installer is within the ZIP file. If you already have the previous Beta Preview release installed, this should install smoothly over the top in the same location. Once installed, this should be version 5.0.149.1. (The previous release was 5.0.1.137.)

Please refer to the original announcement for more details and links to the Google Group where we are handling the related discussions. We’d love to have your feedback, suggestions, and (of course!) bug reports.

A bit filtered (b149)

b149

I have changed the version numbers a bit, reversing the places where I specify the build and channel, so this is now version 5.0.149.0 and if I turn this into the next public beta build, it will be 5.0.149.1. This better matches the build.revision usage, and makes it easier for version checking required program versions for data files. I have not yet changed the version numbers on GCA5.Interfaces, I’m waiting until I actually need to make other changes to that assembly before I do that.

Changed the version checking method for when book files specify the program version.

* Classic View

I’ve added a filter pane for filtering Library trait lists (except attributes). Its visibility is toggled with the new Filter button to the right of the categories drop-down list. The visibility setting applies across all the trait tabs (except Attributes), but any specified filter text will be cleared when you change tabs. The filter text is entered into a drop-down list, so if you want to apply the same filter across tabs, or you want to reuse a filter during a session, you can select it from the drop-down list.

For the time being, I’ve removed the disabled Customize button. I may return it later or I may integrate its intended function into the filter pane; we’ll revisit that in the future.

* Library list

On the Unified and Sheet views, I’ve updated the library list filter pane to also use a combo box.

* Data Files

Made some fixes to Dungeon Fantasy RPG.gdf.