jfreerails.server
Class MapFactory

java.lang.Object
  extended by jfreerails.server.MapFactory

public class MapFactory
extends java.lang.Object

This class has a static method that converts an image file into a map.

Author:
Luke, Scott Bennett (Updated 23rd Jan 2004) Implemented Terrain Randomisation to randomly position the terrain types for each tile on the map.

Field Summary
private static java.util.Vector<java.lang.Integer> countryTypes
           
private static java.util.Vector<java.lang.Integer> non_countryTypes
           
private static WorldImpl world
           
 
Constructor Summary
MapFactory()
           
 
Method Summary
private static void setTile(int x, int y, FreerailsTile tile)
           
static void setupMap(java.net.URL map_url, WorldImpl w, FreerailsProgressMonitor pm)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

countryTypes

private static final java.util.Vector<java.lang.Integer> countryTypes

non_countryTypes

private static final java.util.Vector<java.lang.Integer> non_countryTypes

world

private static WorldImpl world
Constructor Detail

MapFactory

public MapFactory()
Method Detail

setupMap

public static void setupMap(java.net.URL map_url,
                            WorldImpl w,
                            FreerailsProgressMonitor pm)

setTile

private static void setTile(int x,
                            int y,
                            FreerailsTile tile)