Monthly Archives: October 2013

Dragged bits

Loading a character should no longer spit the character’s load-log into the Info pane.

Altered the library loading of system traits to make duplicate x() tags merge their list values when duplicates are found, rather than the standard behavior of replacing values. There is a lot of ‘dirty’ data in the data files where these tags are duplicated to add additional info, and in the case of the x() tag, this was passively allowed in GCA4 (due to it finding the #directives anywhere in the tag data, regardless of duplicate tags). Due to GCA5 actively refusing duplicate tags during the loading process, the duplicate data for the x() tag is lost, so the old, forgiving way does not work now. This new merging behavior should allow the multiple x() tags to work in GCA5 by merging all the duplicate data into a single x() tag. This means that a number of ‘wizard’ type traits, such as the various skills starting with _, and of type %typelist, will now work as intended again.

Also altered library loading of page() to merge values.

The changes to Library loading of system trait x() and page() tags necessitates rebuilding FastLoad files, so the FastLoad version has been changed. Your FastLoad files will be rebuilt as a result.

Updated the code in the Classic View character trait lists so that double clicking the column headers will allow you to turn back off the OrderedBy status. That is, double-clicking will cycle through Ascending, Descending, and Off. Off will restore the list display to the standard order.

Updated the Classic View character trait lists so that adjusting the points/level/cost of traits will preserve their OrderedBy status within the list–rebuilding the list to show the updated order as traits are incremented or decremented. (Note that this may not be entirely desireable when you have a giant list of items, but it works reasonably well for moderate or small lists.)

Updated the Compact View trait boxes to allow double-clicking on the column headers to order the box contents, as in Classic View. Note that the Compact boxes will not re-order the display while adjusting values, unlike Classic View, because the boxes allow for adjusting directly on the trait line itself, and it’s rather annoying to have the interaction area jump to another part of the box while you’re trying to use it.

Changed the sort order markers in trait lists to always be small triangles, although it’s possible to choose between gray (the default), red, and yellow markers. This selection is still by right-clicking on the headers in Classic View, and is now on the box’s option menu (the gear icon) in Compact View. Each marker selection is individual to the type of items. You can also set them in the Colors & Layout dialog.

You may now drag and drop traits from the Library panel onto trait boxes in Compact View, to add them to the character. Any type of trait may be dropped onto any trait box, but they’re added only to the appropriate box. You may now also drop traits onto the sheet area of the Sheet View to add them to the character.

You may now drag and drop traits from the Library list to the Character list in the Classic View.

You may now drag and drop to rearrange the order of User Ordered Layers in the Armor Layers Manager.

The Colors & Layout dialog has been upgraded. It now uses the correct boxes for each box type, and will use sample data from the current character (or from a system sample character, if no other character is loaded). You can also drag and drop the box names within the list box to reorder them, instead of having to use the up and down buttons.

You can now elect to manage the ordering of your character’s traits yourself, if you turn on User Trait Ordering in Options > Current Character Options. When in this mode, traits are shown in the order they are added to the character, but you can drag and drop the traits into new positions in the various trait lists. [Plug-ins note: If you want to implement display support for this feature, check the AllowUserTraitOrdering property, and if True, access traits with either DirectItem(Index as Integer) instead of Item(Index as Integer), or use the new Item overload Item(Index As Integer, DirectAccess As Boolean).]

The OrderBy system in the SortedTraitCollection has been adjusted. [Plug-ins note: If you change OrderBy, it will automatically rebuild the ordered list. However, calling OrderBy if the OrderBy string has not changed will not trigger an OrderItems rebuild. You should still call OrderItems to rebuild the list as necessary if you’re ordering by something that changes, such as points or level, but there’s no need to call OrderItems when new items are added to the collection otherwise, as they’ll be inserted into the ordered list as items are added to SortedTraitCollection.]

Function bits

* The Find Traits window is now available.

* Added support for upformula() and downformula() for Attributes. Using these tags allows you to specify a formula to use for calculating the cost of the attribute when raising or lowing the attribute from the base value.

* Added support for an ‘onlyif’ clause in bonuses. This is basically the same as the ‘unless’ clause, but may be easier for some folks to visualize, because it’s positive instead of negative. OnlyIf is used in the gives() bonus structure after ‘upto’ but before ‘unless’, like so:

‘+2 to SK:Skill [ upto 10][ onlyif TARGET::tag > 0][ unless TARGET::tag = 0][ when “running from danger”][ listas “Some bonus text”]

OnlyIf and Unless both restrict when a bonus is applied. You may use either or both, but if you use both in the same bonus, you must keep in mind that OnlyIf is checked first, and if the target DOES NOT satisfy the requirement, then the bonus WILL NOT be applied, regardless of the Unless statement. The Unless clause further restricts bonus application to traits that satisfy the OnlyIf requirement; it never restricts or excepts the results of the OnlyIf clause. If you only use one or the other clause, then when the exception or requirement applies should be fairly clear.

* Added the @TextIsInText(<IsThis>, <WithinThis>) function to the Solver, which returns 1 if the <IsThis> text is contained within the <WithinThis> text, and 0 if not. As with most such things in GCA, case is ignored.

* Added two new functions to the Solver, which allow for searching for a text item within a list of text items:

@TextIsInList(<IsThis>, {<Within This Comma Separated List of Items>})
@TextIsInListAlt(<IsThis>, <UsingThisSeparatorCharacter>, {<Within This List of Items>})

These are similar, except that @TextIsInList assumes a comma separated list of items, as is used in the cat() or page() tags, while @TextIsInListAlt allows you to specify the character used for separating the items in the list, such as the pipe (|) character used in skillused(). You should always enclose the list parameter inside braces to ensure safely defining the list of items as a single unit. You can, of course, either specify the list items manually, or obtain them using something like $textvalue(me::cat). Comparison of items ignores case, as always. The value returned is 0 if the item was not found, or the index number (1-based) of the list item that was matched.

* Addressed some drawing/refresh related things on the Protection Window.

* Addressed issue related to body image file support in the Protection Window.

* Fixed a bug locating the system images bin.

* Fixed an initialization issue with system traits.

* Made some minor adjustments to the list-based trait boxes in Compact View.

NOTE:

* Removed the old versions of the various trait boxes in Compact View. Please let me know if you see any issues with screen updates or other weird behavior in Compact View.

* Changed the folder references used internally. Also changed how they’re stored in the Folders section of the gca5.prefs file. If you’ve never changed these, nothing should be different, because the defaults are the same. However, if you have changed them, you’ll need to update the new versions.

Scaled bits

You can now right-click on the paperdoll image in the Protection window to access a context menu of some related functions.

You can now resize the body part boxes on the Protection window using the mouse.

Fixed a teeny little wiggle of an issue with the dragging of body part boxes in the Protection window.

Adjusted the look of a couple things in the Protection window.

Addressed some major issues related to scaling the Protection window for Zoom modes other than Normal.

The Library panel (used in Compact and Sheet views) has been updated so that type-to-search works like it does in other places. It has also been updated to respond to the same keys as other areas for adding traits to the character.

Ordered bits

Updated Protection and Loadout windows to add and remove items from loadouts, related protection lists, and ordered layer lists, more robustly.

Removed the Loadout Manager button from the Protection window. It doesn’t actually work correctly given the need to allow the user to Cancel out of the window.

When doing the User Ordered Layers, I forgot to include support for the overall DR bonus, which comes from an attribute that has no location() or dr() tags. I worked up some code to include support for it.

Added some spiffy new interactive stuff to the Protection window.

You can also now drag the body part boxes around with the mouse in the Protection window. This should greatly simplify creating custom layouts.

Because it’s now so easy to adjust the location of the displayed body part boxes on the paperdoll, I’ve allowed the print/Compact view versions of the paperdoll image to grow the box downward as necessary to display excess content.

When using User Ordered Layers, GCA will now tag each layer’s value in the DR box with a footnote symbol, and the footnote symbol will be associated with the item granting that layer of protection. (The footnote symbols are the standard SJGames ones, without the * of course, so they’ll double and triple up once each of the available four symbols is used.) For now, you can see the symbol associations in the Layers pane (see below) of the Protection window. I’ll see about doing something for the Compact view Protection boxes later.

Testing some stuff: If you have User Ordered Layers, a Layers pane (much like the Layers window) will appear on the Protection window. You can resize this pane. You can click one of the two buttons in it to switch orientation between Horizontal and Vertical. You can click the other button to toggle between three different separators for the DR values: plus sign (the default), bullet, and space.