Chit Activation = highlight

Grr, one step away from finishing up this module and despite the abundance of topics on the matter and the module guide I just can’t make it work. I must be getting caught up in the verbiage.

I have a chit draw cup of which some of the chits are for Activation of a counter on the main map. For sake of example let’s call one of these 'French 1". Basically I would like it so that when chit ‘French 1’ is drawn from the cup, the programming centers onto the ‘French 1’ counter which is located on the Main map and gives that counter a highlight layer.

I use Global Key Command for this correct? Which activates Layer - French 1?

Or am I way off?

Jean

If the chit drawn is named “French 1” and the piece on the board you wish to highlight is also called “French 1”, then you should be able to use the property filter

CurrentMap = (map the piece is on) && BasicName = $BasicName$

I don’t know how you are activating the layer, though. Are you using a Dynamic Property to control it? This would probably be your best bet.

Salut Dr.

Yes. When I draw the relevant chit from the cup I have a Dynamic Property with the following Value:
CurrentMap = MainMap && BasicName = French I

with Menu Command: Activate
Key Command: Ctrl A
Type: Set Value Directly

The counter on the MainMap is called: French I
and has Layer called: Activate
key: Ctrl A

Am I missing a step or is the problem simply bad syntax?

I appreciate your help.

Jean

What do you mean you have a DP with those values?
CurrentMap = MainMap && BasicName = Whatever is a property match expression which are usually found in Triggers or GKC’s - not DP’s
Please provide a pic

I guess I misinterpreted DrNostromo’s message.

First pic is of Chit which is pulled from a Turn Map.[attachment=1]Chit.jpg[/attachment]

Second pic of of Marker on Main Map I would like to highlight when Chit is drawn.[attachment=0]Marker.jpg[/attachment]

Jean

ok you got it right - you meant GKC not DP :slight_smile:

This looks like either a foreign keyboard issue? or a input error…

see how you have “CTRL A” in the GKC but “^A” in the layer, that isn’t going to work because the keystroke has to be exactly the same

This is what the Layer dialog looks like on a Mac. Editing a module on a PC, you see CTRL in that entry box. Edit the same module on a Mac, and you’ll see ^ as shown in his screenshot. It’s odd, but I guess I’m just used to it by now.

see how you have “CTRL A” in the GKC but “^A” in the layer, that isn’t going to work because the keystroke has to be exactly the same

Is there a work around it Joel if that is indeed the issue?

Jean

Sorry, I didn’t clarify enough. You are sending a CTRL-A. In this one dialog box on a Mac, it displays ^ when you press the CTRL key instead of “CTRL”. In my experience, they are identical keystrokes–I do a lot of editing on both Mac and PC and see this all the time.

try Shift A or Alt A or just A :slight_smile:


From: jtessier jean@tactiquesnapoleon.com
To: messages@vassalengine.org
Sent: Tue, March 13, 2012 1:51:25 PM
Subject: Re: [messages] [Module Design] Chit Activation = highlight

see how you have “CTRL A” in the GKC but “^A” in the layer, that isn’t
going to work because the keystroke has to be exactly the same

Is there a work around it Joel if that is indeed the issue?

Jean


Read this topic online here:
https://forum.vassalengine.org/t/chit-activation-highlight/4751/8


messages mailing list
messages@vassalengine.org
vassalengine.org/mailman/listinfo/messages


messages mailing list
messages@vassalengine.org
vassalengine.org/mailman/listinfo/messages

Duh me…Looking at the pictures more closely reveals part of the problem. You appear to be missing some stuff? You have the layer following a non existent property value (check box is on but property name is empty or missing). You either have to complete this with a corresponding DP/marker or uncheck it on the layer

Hi Tim,
Property Value in Layer has now been unchecked. Alas to no avail.

I keep thinking the problem is in my GKC “Matching Properties” line: CurrentMap = MainMap && BasicName = French I

Can I confirm that MainMap is the name of the [Map Window] and not the [Board] which is different. In my case it’s called “1809-Corunna”?

Can I confirm that it’s 2 ampersands not just 1?

and finally that it’s “BasicName” and not “BasicPiece”?

I feel like I’m one keystroke away from victory… only to have my plane shot down. Welcome to wargaming I guess. :slight_smile:

Jean

No Jean, your expression is spot on

Correct, MainMap is the name of the Map window

Also correct

Yep

Something else must be going on in your module then that we are not seeing. Can you post a link to the module?

Is it MainMap or Main Map the actual name of your map?

Because before the second pic you write “Second pic of of Marker on Main Map I would like to highlight when Chit is drawn.”

If it’s “Main Map” then just fix your property expression adding the missing space.

I think I got it.
I stared the whole thing from scratch and I can now invoke the GKC to activate the highlight layer. Hourrah!
(Now to see if I can do it with the chit draw. :slight_smile: but that’s another story!)

Thank you so much everyone for your help. Much appreciated.

And now a la guerre!

Jean