[messages] [Module Design] Trouble with Counting of property expressions

starfish krhogan at gmail.com
Fri Mar 20 22:56:45 CET 2015

Hello All.

I am creating a vassal module for the game Guillotine.  This is a card
game.  Players collect various cards, each which has a certain value.
I have added markers to each card that determine the value.  Marker 
VP=1  for a card worth 1 point,   VP=-1 for one that is worth negative
points, etc.  I also created a marker for color;  Color=Blue.

Deck: -->Player1WinPile
I have checked the "Perform counting of property expression?" and have
added the following (based on the game Dominion)
"VPCount1:VP=Calcuate".   I have placed two cards in this deck for now
worth 5 VP each, both blue.

At-Start Stack:  --->VP for Player1
I also created an at-start stack to report the VP value.  So,  it has
VP: $Player1WinPile_VPCount1$ as the text value.  

At-Start Stack:  --->Color Count Blue for Player1
I also created an at-start stack to report the Color count, blue.  This
work and shows a value of 2.  

For testing, I created a Toolbar button that activates a global property
change to set change VP1 to "$Player1WinPile_VPCount1$" and reports this

So, I thought this would work, but it is not.  The At-stack shows 0, and
the toolbar runs one and shows my text, but nothing for VP1.

Is my syntax right for calculating the value of VP?  

I was also wondering if I can use the "Calculated Property" Trait to
track VP for certain cards that are worth more depending upon how many
of that kind are in the current deck.  So I need a formula to that
counts how many of this card are in the current deck and sets this as
the value.  Something like "$Current_Deck$_PGCount" so if 3 are in the
deck, VP is set to 3.  Is there a value for current deck I can


Read this topic online here:

More information about the messages mailing list