Building an expression for an Inventory Report

This should be so simple, but I cannot figure this out.

I want to create an Inventory using the “Game Piece Inventory Window” where the Trait, Layer, and where the name of the layer does not equal Flip. Pieces, not all, that have a Trait Layer have only one such Layer and it needs to be named Flip however I have found that some are named incorrectly. With over 1600 pieces, I need a quick way to find them,.

I cannot figure out the proper expression to use with “Show only pieces matching these properties”.

Any help would be greatly appreciated.

It might be easier to use the Search functionality in the editor, searching for the incorrectly named Layer.

1 Like

That might be but again it needs an expression and I still do not know how to use Expressions properly. I am very new to this.
Here is an example of a counter’s Traits
image
So as you can see the Trait of Layer has a name of Flip, and for that Layer there is only 1 level in which the Level name is blank.

What I need to find are all counters where the Trait, Layer, is NOT named Flip.

FYI: The counters were setup based on the Reference Manual: For a basic two-sided counter, add a Layer, and select an image that represents the reverse side. Change “Activate” to “Flip” and set the key to Ctrl+F.

Flip_Active==“false”

That will exclude any counter where Flip is active.

I’m afraid there is no easy way to do this; you can’t search for Layer traits that don’t have a specific name in the editor, and while it should theoretically be possible to use a regular expression search on the buildfile.xml file stored in the module, the format is extremely opaque and difficult to parse (based on my perusal of buildfile.xml in the module “Terraforming Mars”, the Layer trait is represented by the string “emb2” followed by its various parameters, separated by semicolons; I counted 18 semicolons between emb2 and the name of the Layer trait, but I’m not sure if that’s consistent, and my attempt to put together a regular expression to search for that failed–I tried emb2;(.*;){17}<layer name here>, but it didn’t work and I couldn’t figure out why).

I was hoping it was something simple but it appears not so. Thanks, jrwatts for your reply. Sadly, the original creator of the module did not include an Alternate name for the level but then again he probably did not think it would be necessary.
I really like this Vassel engine and I especially like this forum.

I just did a search of the buildfile.xml and slugged my way through looking for emb2;A and then em2;B , skipping emb2;F, all through emb2;Z, and that did it. Slow but it worked. Thanks jrwatss for the heads up!

1 Like