I’ve searched for a while but didn’t find an answer, also took a look at the example given in http://www.vassalengine.org/forum/viewtopic.php?f=6&t=5287, but that only seems to confirm what I’m afraid of…
I want to create a random map using tiles. I’ve got that working so far, but my question is, do you really have to create/copy-paste each tile in the card deck or is there some way of telling vassal it should place 10 of card A, 5 of card B, etc… in the deck?
The map - for now - is going to be about 10 x 10 tiles, so I’d have to create 100 cards, more importantly, for different scenarios, there should be different ratios of the tile/card types. Is there any way, to just create 1 card for every tile type (e.g. woods, plains, mountains,…), then tell vassal how many of each card should be in the deck?
Any help would be greatly appreciated!
I had a similar problem on a module I’ve been working on, where I had a # of copies of a particular counter/tile,
that only differed in one property (a count value, in a particular property).
What I did, was a combination of
a) a ‘Place Marker’ trait, to create the piece (with a prototype attached, to define functions on the newly created piece)
b) a Trigger action, using a loop, that called the Place marker trait, then decremented a counter variable.
Use the ‘Perform this keystroke once before’ looping starts’, to load the initial value of the counter var.
and stop the loop when your loop var hits 0.
I used a global var as my loop counter, so that I could then (by using the ‘Apply keystroke after placemnent’
entry on the Place Marker, copy that value into a Dynamic Property on the newly created counter
(That being defined in the prototype that was added to the counter in the PlaceMarker command)
If this wasn’t clear enough, let me know; I can provide screen clips of the actual definations.