Properties from another map

In my module, map1 contains a deck “deck1”.
In map2 I want to create a text label to count the number of cards in deck1 but when I try “$deck1_numPieces$” or “$map1_deck1_numPieces$”.
How can you do that?

I think text labels can only display properties on a piece, or global properties.

the text label is on a single piece that is in a at-start-stack

$deck1_numPieces$ is the correct expression, unfortunately it can not be
read across maps - only in the map that contains the deck

-----Original Message-----
From: messages-bounces@vassalengine.org
[mailto:messages-bounces@vassalengine.org] On Behalf Of HealingAura
Sent: Sunday, January 15, 2012 12:16 PM
To: messages@vassalengine.org
Subject: [messages] [Module General Discussion] Properties from another map

In my module, map1 contains a deck “deck1”.
In map2 I want to create a text label to count the number of cards in
deck1 but when I try “$deck1_numPieces$” or “$map1_deck1_numPieces$”.
How can you do that?


Read this topic online here:
https://forum.vassalengine.org/t/properties-from-another-map/4587/1

True …but you may be able to set the cards to trigger a Set Global Property trait when they are drawn. Create a Global Property called something like Deck1CardCount and set the GP to $deck1_numPieces$ whenever a card is drawn. Then have your text label display $Deck1CardCount$

If the card is being drawn to a different map than the map containing deck1, create an invisible At-Start stack piece on Map 1 to control the SGP. Then have the card send a Global Key Command to the At-Start stack piece to trigger the SGP.