Page 1 of 1

Global Invisibility Trait

PostPosted: July 28th, 2020, 2:44 pm
by keefersa

I'm trying to create a trait for a whole class of counters, rendering them invisible and immobile as a group on a global key command, and am running into difficulties. I'm not sure how to enter invisibility and as a property here, and how to do it in a way that would simultaneously render all counters of this type invisible/immobile. Ideally, I'd like to hit a command key to hide/unhide all military counters as part of a diplomatic history game.

Any help would be appreciated.

Re: Global Invisibility Trait

PostPosted: July 28th, 2020, 10:24 pm
by grouchysmurf
Invisible for one side only? Invisible for all players?

Idea: let all the counters have a layer, activated. Don't select image for the counters themselves; when layer is activated, it "constitutes" a counter, so to say. Have a GKC to activate / deactivate the layer.

Re: Global Invisibility Trait

PostPosted: August 2nd, 2020, 4:54 pm
by keefersa
Hi again,

the more I dig into this, the more I end up getting stuck, although this is my first module. I've been trying to put together a GKC as suggested for this with no luck, so I decided to take a step back and build the example in the designer's guide (page 48), simply creating a rally trait with a GKC and am getting nowhere. I can create and activate a separate layer, but am unable to get a GKC to automate this.

To retrace my steps: I created a Marker for the infantry counter, with property name "Infantry" and property value "Infantry" then created a Layer level named Rally, with a separate image layer activated by CTRL A.
On the leader counter, I entered a description "Rally Infantry Units" command name "Rally" and global key command CTRL A. The Matching properties was filled in with "type=Infantry && Rally_Active=false"
Do you know what I'm doing wrong here? Any help would be appreciated.

Re: Global Invisibility Trait

PostPosted: August 3rd, 2020, 9:50 am
by grouchysmurf
Conditions can be tricky in Vassal. Checkv out the working example: ... .vmod?dl=0

Re: Global Invisibility Trait

PostPosted: August 5th, 2020, 4:42 pm
by keefersa
Thanks for your help and the concrete example - this was really a lifesaver. I wasn't using the beanshells around the matching properties, among other things. More generally, it helps to get a sense of how to use markers, matching properties, GKCs, which provide a range of options. I think this will do what I want it to do now and it works perfectly for the invisibility trait, although I'm also experimenting with a Game Piece Layer - not sure whether there will be other advantages or disadvantages. I'm putting together a grand strategic game and wanted a separate layer for diplomacy, military, and economy so as to be able to filter these things out when not needed.

On to the next task, figuring out how to add up provincial economic values and run calculations with them.