Check which boards are in the game

Hi all,
me again. Sorry if this has been asked before, but for all questions I could think of, the forum replied “too common search words”.

My map my have up to 3 boards: western (optional), main (mandatory), eastern (optional); the optional/mandatory is real-life logic, not a logic to be applied within VASSAL (just curious: could it be?). I want to check which of the optional boards are in the game, with the aim of automatically adding certain overlays.
I think I could place at-start-stacks on the optional boards, each with a “dummy” piece that has the “set global property” trait; they would set global properties I can access elsewhere (for example to calculate which overlays show, if I implement the overlays as at-start pieces with a (calculated) layer trait). However, this solution needs a command sent to the pieces, or they will do nothing.
Is there a way to get the information without issuing a command? Or, second best, a way to issue a command automatically when opening the module (or a certain window)?

Other things I considered: Placing at-start pieces with certain global properties on the optional maps; unfortunately I found no way to access these zone-level global properties from a level “above” (e. g. module level). Other ideas foundered because it seems that VASSAL stops evaluating expressions when it encounters an error (?), such using for a global property that has not been defined (tests seem to indicate that it does not simply send back nothing, but stops evaluating, but I am by no means sure about that).

I don’t know about your first question: making one of the boards mandatory and the others optional.

As for alerting you of these alternate maps in-game, your dummy pieces should work great I think. Use the Start-up GKC trait for the main toolbar to fire them. Note that it will fire every time the game is opened (i.e., repeatedly throughout the game, if a game is pbem or saved). This may not matter for what you’re asking it to do, but if it does, then you’ll want to add its own global property to it, preventing it from repeatedly firing.

The Startup GKC is what I was looking for, thank you! I guess I should abandon the PDF manual (3.1 seem to be the latest version vailable) as it does not know about this trait.

Splendid, it works. For reference:

The startup command sends the command key “startup_command” to all pieces. On each board there is an at-start-stack with overlay pieces; one of the pieces per board reacts to the command (in its “set global property” trait) and sets a module-level GP “HasMap>name>” to 1 (start value was 0) if the board is in play (otherwise it can’t because there is no piece to react to the command).

By querying the GPs I can automatically place certain overlays (by calculating the layer they should show). The module is still Advanced Civ, and the overlays are, for example, those starting zones that change with the game board configuration.