The Colossus Battlelands Randomizer
To create the program, just type "make tools" or
"ant tools". See
for more details. This should create all the tools for Colossus, including
BattlelandsRandomizer uses an input file that describes the
properties of the future Battleland, and generates one random Battleland.
At the moment, it's a purely static, text-based process.
The Randomizer used can also be accessed from inside
, in a much more user-friendly way. An input file (described below) is
Examples of random input files can be found in the
Properties are lines of one of the three forms:
AREA <list_of_hex> HAZARDS <list_of_hazards>
LABEL <label> = <list_of_hex>
PAIR <pair_of_hazard> HEXSIDES <list_of_hexsides
are the strings literals ; = is the character literal
- <list_of_hex> is a list of hex from the following available
where <number> is a number between 0 and 5, and <range> is
of the form <number>- <number> i.e. a range of number
between 0 and 5. <hex_label> is simply the label displayed on the
Battlemap (F4, C3,...) <label> is a label defined previously with
statement (see below)
"(" <number>, <number >")"
"(" <range>, <range>")"
"(" <number>, <range>")"
"(" <range>, <number>")"
SOMEOF"(" <number>, <list_of_hex
SUBSTRACT"(" <list_of_hex>, <list_of_hex
There are some predefined labels available, including
- "inside" representing everything but the most outside
- "leftdefenseentry", "upperdefenseentry" and
"lowerdefenseentry", the 3 lines of 3 hexagons
representing the defense entry lines (left, upper-right, and
- "anywhere" representing the whole Battlelands.
- "leftover" : special label representing all hexes
that were in the most recent
statement, but didn't receive a Hazard.
- "usedup" : special label representing all hexes that
were in the most recent
statement, and did receive a Hazard.
is a literal string ; result is a list of <number> hexes taken
randomly from the <list_of_hex> in parameter.
is a literal string ; result is the list of hexes adjacent to any
hex(es) in the <list_of_hex> in parameter. Note that all hexes
present in the <list_of_hex> are excluded from the
is a literal string ; result is the list of hexes that are in the
first list but not in the second.
- <list_of_hazards> is a list of Hazard from the following
<hazard_letter>(, <probability>)?(, <elevation
where <hazard_letter> is a letter representing a
Hazard ('r' for Brush, and so on, see BattleHex.java),
<probability> is a float number representing the percentile of
chance of the hazard being present (a numerical point _must_ be
present for all probability), <elevation> is a hard-coded
elevation (integer between 0 and 2), and the three
<probability_elevation_X> are the odds of the hazard being at
elevation 0, 1 and 2 respectively (it's better is the sum is
100., but they will be normalized to percentile values). Only the
<hazard_letter> is mandatory, the other parts are optionals.
But if those other parts are present, they must respect the order
above (first probability if present, the either the elevation or the
- <label> is a lowercase-only string, that act afterwards as it
was the list of Hex on the right side of the '='
- <list_of_hexsides> is alist of <hexside_letter>,
- <pair_of_hazard> is a pair of "("
<hazard_letter>, <elevation>")". Elevation can be
0, 1, 2 or the character literal *, which means 'any
elevation'. For all hexside between such a pair of hazard, all
hexside from the <list_of_hexside> will be tried in order, until
either one is present, or all have been tried (in which case no hexside
will be used between the two hazards). Not that the default Hazard, the
plains (character 'p'), can be used.
BattlelandsRandomizer will then, for each
, try to put the Hazard in any one of the Hexes in the
. A Hex will not receive two hazards, but if a Hex is present multiple
times in the same
, it may receive one Hazard per occurence of the Hex. In this case, only
the last Hazard is used.
s are processed in order, so an Hex that appears in multiple
may also receive multiple Hazards. In this case only the last Hazard is
Note that all hexsides use the same
-defined probability. Only the last
statement is used for a given pair. For this purpose, all elevations
including * are different. The more specific statement will be used (i.e.
(s,0)(p,0) will be used instead of (s,*)(p,*) for the hexside between a
0-height Sand and a 0-height Plains).
Finally, you can give the random maps a title and a subtitle