Is it possible to parse Strings in Zone Global Properties?

This is what i’m planning to do:
On the main map i have some zones. These zones have a global property which should “automatically” change some properties of the Piece that enters in the zone.
My “istinctual” approach, as a programmer, is to set this Global Property (call it “ModTypes”) as a string, with each character defining a “trait” of that zone.
So, as example, a “Mountain” zone should have the ModTypes property set to “MCR” when “M” = Mountain, “C” = cold, R = range.
The piece which enter in the mountain zone should check each character of the ModTypes value and, as example, inrease the “Fatigue” property by 2 'cause the “M”, decrease the Life Points by 1 'cause the “C”, and have a range of sight increased 'cause the “R”.

Now, i just don’t know if this is a feasible approach in Vassal, so before writing the whole map i ask if i’m just dreaming :slight_smile:

I don’t believe it’s possible in the current version of Vassal. The next version may make that possible as the BeanShell mathematics engine is supposed to be incorporated into it and I think that will allow parsing.

In the meantime, you can attached global properties to a zone. In your case, you can address each mod type separately…

TerrainType = M
Temp = C
etc.

…and then address them separately.