private windows

Hi all,

I am new to making modules and need some help.
I want to reveal the contents of a private window to all players OR
move all cards from a private window to a public window or a map BUT
I need to keep the layout of the cards the same.
Its a hidden movement game and when the game is done I want to show all the moves

Any help?


This is actually a huge pain to do, and different people have come up with different solutions. Here’s my bid:

  1. Create a private window ‘Results’ which does not belong to any player but is visible to all players. Maybe make one for each player, go crazy. This window should be the same size as your players’ regular private windows.
  2. (probably not necessary) Give each card two dynamic properties ‘LayoutX’ and ‘LayoutY’
  3. Give each card a Trigger Action that will do:
    3a) (probably not necessary) Set LayoutX to $CurrentX$ and LayoutY to $CurrentY$.
    3b) Send to Location - Map: Results, Board: whatever, X Position: $LayoutX$, Y Position: $LayoutY$. Give it a ‘Send Back’ keyboard command too. Leave both the ‘Command name’ and ‘Send Back Command Name’ blank or they’ll show up in your right-click menus, which is embarrassing. The reason (2) and (3a) might not be necessary is that you might get away with just putting $CurrentX$ and $CurrentY$ into this Send To Location. But maybe not. I don’t know or remember when those $properties$ are evaluated.
  4. Create a piece with no image, maybe call it ‘SendManager’ or ‘PixieAssassin’ or something. Put one copy on each of your regular private windows. Make it ‘Does Not Stack’ to be extra cautious, maybe.
  5. Give the SendManager piece two Global Key Commands - one should fire the ‘Trigger Action’ on all pieces matching ‘CurrentMap = $CurrentMap$’. The other should fire the ‘Send Back’ command on all pieces matching ‘CurrentMap = Results’
  6. Create, like, a toolbar button or something to ‘Show Pieces’ and one to ‘Return Pieces’. These would be, again, global key commands, but instead of adding them as traits to a piece, you would add them to your private windows. The ‘matching properties’ should be, like, ‘BasicName = SendManager’.

That…should be enough to make it actually work. If not, split up the process to see what’s not working - so, add a ‘Menu Command’ to your Trigger Action and see if you can fire it manually, for instance. Add reports to see if your pieces are receiving their global key commands. That sort of thing. Once it does work, there are many things that could be improved. You might try to figure out a way to add a prompt to the ‘Show pieces’ button to warn people that this should only be done at the end of the game. Or you could find a way to move the toolbar buttons to the Results private window, by using the $playerSide$ system property.

Anyways, there will be a much better way to handle this in V4, by dynamically changing the visibility of the private windows. For now, this is the best I can come up with.

Thanks for the help. Its all working. I didnt have to add the extra locationX stuff. The rest of your advice worked great and I learned alot.
Uploaded tonight !!!

Oh, I forgot to mention why the intermediary SendManager piece is necessary, rather than just having your toolbar GKCs address the cards directly - and it’s something that seems to trip a lot of people up: in 3.1, toolbar GKCs can only address pieces in their own window. So you could have a toolbar GKC send all your pieces to the Results window, but you would need a GKC piece trait to get them back - since they’re now in a separate window. In 3.2, toolbar GKCs can do this directly and there is no need for a SendManager piece.

Glad to hear it worked out for you!