Create account / Log in

Region Name strictly parsed; generates spurious error

Issues with the Vassal engine.

Moderators: uckelman, Tim M

Region Name strictly parsed; generates spurious error

Postby marktb1961 » December 27th, 2020, 12:19 am

Vassal seems to be over sensitive about the contents of the Region field in "Send to Location" trait.

example; at a certain point (e.g. after a Refresh Counters but also in normal use), the following form of error will be generated if the Region field parses out to a value that does not equate to a valid Region name:
- Bad Data in Module: Recon in Force [Send to Location - Play multisection CC card in front of CiC] - Region not found Region[{ "CPCiC" + (OldMap=="Courier Rack" ? 1 : 2)}]= CPCiC2

My point is that there are valid reasons why the Region may not exist. My particular use case is a game with two map types, where one map type doesn't need the same Regions defining as in the other map type. I could quite easily make sure that the invalid Region name is never referenced (e.g. Restrict Commands).

The workaround is to ensure that any expression for a Region Name always generates a valid Region for any maps involved but I wonder why the Region name parsing is so strictly enforced.
Platform: Vassal 3.5.3, MacOS Big Sur on iMac (27", mid-2020)
User avatar
marktb1961
 
Posts: 521
Joined: October 4th, 2018, 2:36 pm
Location: Liverpool, England

Re: Region Name strictly parsed; generates spurious error

Postby m3tan » December 27th, 2020, 12:59 am

I find it useful because it identifies typos and other bugs in my buildfile that would otherwise go unnoticed as Vassal has no debug capabilities. That said it would be nice to disable these warnings type messages that aren't fatal errors.
User avatar
m3tan
 
Posts: 236
Joined: August 12th, 2018, 11:49 pm


Return to Technical Support & Bugs

Who is online

Users browsing this forum: marktb1961 and 4 guests