Senior Member
Join Date: Jan 2007
Location: NW Arkansas
Posts: 1,321
|
Howdy!
I am working on a dataset where items in the core book can be classified as being part of “Past Era”, “Present Era” or “Future Era”. This works fine with an Era source group and just the three selections. My difficulty comes with sourcebooks. A sourcebook can add material to any or all of the eras. How can I make sure that an item added from a Sourcebook is only visible when the valid Era is also selected (I.e. both Past and Sourcebook 1 have to be selected for Past material from Sourcebook 1 to show)? As it is, if an item has an Era and the Sourcebook selected, everything from the Sourcebook shows, regardless of Era. Working on - |
#1 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,207
|
I would add a component to every compset that needs to be era-specific. This component would consist only of a <containerreq> test that looks at a tag group that stores what eras are allowed for that item, comparing it against hero tags that are added by the sources, saying what eras are currently in use. You're basically recreating the sources mechanism with tags, but setting it up in a way that the era choice is independent of the book choice.
Then, the various books would be handled as normal sources. |
#2 |
Senior Member
Join Date: Jan 2007
Location: NW Arkansas
Posts: 1,321
|
Quote:
I would have an Era.? Tag group. On the individual items that are limited by Era, they would receive a Era.Xx as appropriate. The component, within the cointainerreq test would compare the Era.xx tag on the component with the Era source tag on the component and fail if they don’t match? Working on - |
|
#3 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,207
|
The containerreq on the component would compare the Era.xx tag on that thing/pick with the Era.xx tags on the hero, and fail if they don't match. The individual items would not set sources from the Era group - they would need to use a separate editor control to add one or more Era.xx tags
|
#4 |
Senior Member
Join Date: Jan 2007
Location: NW Arkansas
Posts: 1,321
|
Can you use heromatch, tagmatch or intersect in a containerreq? They seem to throw errors.
In this case, the hero has source.Present, and the thing has both Era.Present and Era.Future . I’ve got just heromatch[source,Era] inside the containerreq and am getting an invalid syntax error. Quote:
Working on -
Last edited by TCArknight; March 17th, 2018 at 05:43 AM. |
|
#5 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,207
|
This is a tag expression. Those are all things from the scripting code. You'll probably need to hard code all the comparisons (a separate pre-built comparison for each era).
|
#6 |
Thread Tools | |
Display Modes | |
|
|