Automatisation

Hello, everyone! I am just begining to learn vassal module creation and I have this question: Is there anyway to automate some actions such as: counting movement points for units, health calculation and stuff?

Yes, but with the standard Vassal tools it is quite difficult to do so it
generally is easier to write custom java classes to do this for you (if you
know how to code in java).

vassalengine.org/wiki/Progra … Configurab
le_class

This wiki page gives an example of doing such a thing

-----Original Message-----
From: messages-bounces@vassalengine.org
[mailto:messages-bounces@vassalengine.org] On Behalf Of Ingvas
Sent: Tuesday, December 21, 2010 8:12 AM
To: messages@vassalengine.org
Subject: [messages] [Technical Support & Bugs] Automatisation

Hello, everyone! I am just begining to learn vassal module creation and
I have this question: Is there anyway to automate some actions such as:
counting movement points for units, health calculation and stuff?


Read this topic online here:
https://forum.vassalengine.org/t/automatisation/3518/1

Sure. May take some time to get used to how the Vassal Engine works but automation is quite doable. If it gets complex, it has to be solid or it could get you into trouble with unexpected results. I’m sort of an automation junkie and I’ve spent many a hair pulling sessions trying to figure out what’s wrong with my logic.

As far as calculating things, keep in mind that all the Vassal Engine can do at this time is add to or subtract from variable values using the Dynamic Property and Set Global Property traits. It cannot do mathematical expressions. The next major release of Vassal (3.2) will have a mathematics and expression engine but currently it doesn’t.

If you want a sample of what can be done, give me a scenario and I’ll put a sample together for you. Feel free to E-mail me if you like.

On Dec 21, 2010, at 7:06 AM, DrNostromo wrote:

Is there anyway to automate some actions such as: counting movement
points for units, health calculation and stuff?

As far as calculating things, keep in mind that all the Vassal Engine
can do at this time is add to or subtract from variable values using
the
Dynamic Property and Set Global Property traits. It cannot do
mathematical expressions.

Movement points in particular will be hard because there isn’t
currently any way to represent terrain and terrain costs. There is a
feature request for something along these lines, but that is in the
far future.

I would think that to do this properly would be a bit tricky – unless
you wanted to force a hex-by-hex movement of the units. And then
using some sort of undo, when you need to change in the middle of the
move or because your mouse hand is a bit clumsy.

Thanks for your replies, guys! I guess, I will wait for the next version then.

Hi,

I’d love some guidance on automating various functions in the Pacific War module. Are you familiar with the game? Do you have time to help?

Thanks in advance,

Steve

I don’t know the game but let us know in particular what you want to do and maybe we can come up with something.

During the ‘Strategic Phase’ of the game there are several processes that involve die rolling and chart lookups that require input from both players based on the their choices and the game situation.

I guess to start, how to I setup the module so it ‘knows’ some of this input data?

Then, how do we tell the module how to use it?