rescuecore.tools.mapgenerator
Class MapGenerator
java.lang.Object
rescuecore.tools.mapgenerator.MapGenerator
- public class MapGenerator
- extends java.lang.Object
The main class of the mapgenerator package.
This creates a new random city map for use in the Robocup Rescue simulation.
Method Summary |
static RescueMap |
generateMap(boolean rotate,
boolean nooneway,
int roadDensity,
int buildDensity,
int width,
int height,
int uniformity,
int movement,
int smooth,
java.lang.String initScheme,
java.lang.String connScheme,
java.lang.String buildScheme,
long seed)
Creates a RescueMap object to specification. |
static void |
main(java.lang.String[] args)
Runs the program from the command line. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MapGenerator
public MapGenerator()
generateMap
public static RescueMap generateMap(boolean rotate,
boolean nooneway,
int roadDensity,
int buildDensity,
int width,
int height,
int uniformity,
int movement,
int smooth,
java.lang.String initScheme,
java.lang.String connScheme,
java.lang.String buildScheme,
long seed)
- Creates a RescueMap object to specification.
- Parameters:
rotate
- Whether to randomly rotate the nodes.nooneway
- Whether to allow different number of lanes in each direction on a road.roadDensity
- How dense the roads are - 0..100.buildDensity
- How dense the buildings are - 0..100.width
- Approximate width to make the map in millimeters.height
- Approximate height to make the map in millimeters.uniformity
- How uniform (non-random) to make the map - 0..100.movement
- The maximum amount we can adjust nodes by in meters.smooth
- Total number of lanes a road must be before it has corners smoothed.initScheme
- The scheme to use to initialise the map.connScheme
- The scheme to use to decide on number of lanes per road.buildScheme
- The scheme to use to add buildings to the map.seed
- The random seed.
- Returns:
- A new RescueMap.
main
public static void main(java.lang.String[] args)
- Runs the program from the command line.