How to prevent generating Movement Trail on some maps?

I want to have Movement Trail on the main map, but not on a number of secondary maps where they clutter and have no function. It seems that Movement Trails are “global” in the sense that they apply everywhere, and I can only find a command that toggles the Movement Trail, but not one that turns them on or off,
If I let the secondary map issue a key command for all movement that ends on that map, the Movement Trails are toggled off, but on the next move they are toggled on again, and so on.
Is there a way to see if there is an active Movement Trail? In that case, I could issue a command that toggles it back off, if it is on.
I also need a command that ensures that the Movement Trail is back on when the unit is moved to the main map …

You’re on the right track, but must be using an old version of Vassal. More recent versions of Vassal have enhanced the Movement Trail trait to define additional commands that can explicitly turn trails On (show), Off (hide) or Clear in addition to the (now obsolete) Toggle command.

I suggest that you define a Trigger Action which listens for the command which gets sent when a piece is moved on the secondary map. That trigger would use its Property Match Expression to detect when the piece moved from a different map (to prevent redundant processing if the piece moved around on the secondary map) and send a command to the Movement Trail trait which both turns trails Off and also clears them.

If you need to support the case where the piece is later returned to the Main Map and needs to have trails functioning again, you would use that map’s “ends move on map” command to both clear trails again and turn trails back on.

The above assumes that trails are always enabled on the Main Map. In the case where trails can be turned on and off globally by the user, you should define a Global Variable to remember that current trails setting, and use that property in a Trigger’s property match expression to conditionally per the current global setting.

I hope that makes sense.

Cheers,
Jim Hunter.

1 Like

Silly me! You are absolutely right!

I do use the latest version 3.6.19. I can’t understand how I missed those On and Off commands! Everything you wrote made sense, and I am going to implement it ASAP.

Thanks. :blush: