Fixing a bug in the TTA module

I have been unsuccessful reaching the author of the Through the Ages module.

I’ve spent about 6 hours reading the code, and I think I understand where the bug is.

But I have 2 questions about VASSAL. I have a programming background (java) so I’m trying to understand how to program in VASSAL from this perspective.

  1. Is it true that there are no math expressions? I see a lot of code that appears to be there because you can’t say something like A = B + C.

  2. Is it true that the way you call a function in VASSAL is by issuing a keystroke in one place and then writing a trigger for that keystroke in another place?

The main problem I have when trying to debug the TTA module is I will see the code issue a keystroke, and then I need to find the place(s) that are listening for that keystroke. And there does not seem to be any sort of search mechanism to help you find all the places that are listening for that keystroke.

Is this how things are done in VASSAL? Or has the author of this particular module coded it in an unusual way?

Thanks!
Ken
www.strategicinitiative.org

  1. Is it true that there are no math expressions? I see a lot of code
    that appears to be there because you can’t say something like A = B + C.

This is true for the current version.

  1. Is it true that the way you call a function in VASSAL is by issuing a
    keystroke in one place and then writing a trigger for that keystroke in
    another place?

That’s one way to do it. Most components listen for a key stroke and take
care of it themselves.

The main problem I have when trying to debug the TTA module is I will
see the code issue a keystroke, and then I need to find the place(s)
that are listening for that keystroke. And there does not seem to be
any sort of search mechanism to help you find all the places that are
listening for that keystroke.

That seems to be a common problem. There really isn’t a solution other than
manually inspecting the buildfile within the vmod archive.

Is this how things are done in VASSAL? Or has the author of this
particular module coded it in an unusual way?

I’ve never looked at that particular module. However, if you open up the
vmod file in an archive manager and see a directory full of java classes,
then all bets are off. Otherwise, it’s all there in the module editor
somewhere.

  • Michael.




  1. Is it true that there are no math expressions? �I see a lot of code

    that appears to be there because you can’t say something like A = B + C.

This is true for the current version.

2) Is it true that the way you call a function in VASSAL is by issuing a
keystroke in one place and then writing a trigger for that keystroke in
another place?

That's one way to do it.� Most components listen for a key stroke and take care of it themselves.

The main problem I have when trying to debug the TTA module is I will
see the code issue a keystroke, and then I need to find the place(s)
that are listening for that keystroke. �And there does not seem to be
any sort of search mechanism to help you find all the places that are
listening for that keystroke.

That seems to be a common problem.� There really isn't a solution other than manually inspecting the buildfile within the vmod archive.

Is this how things are done in VASSAL? �Or has the author of this
particular module coded it in an unusual way?

I've never looked at that particular module.� However, if you open up the vmod file in an archive manager and see a directory full of java classes, then all bets are off.� Otherwise, it's all there in the module editor somewhere.

- Michael.