Exemple #1
0
        static MapTile()
        {
            parkMapTiles = new MapTile[parks.Length];
            for (int ind = 0; ind < parks.Length; ind++)
                parkMapTiles[ind] = new MapTile(TYPE.PARK, DIRECTION.INTERSECTION) {SpriteBitmap = parks[ind]};

            officeMapTiles = new MapTile[offices.Length];
            for (int ind = 0; ind < offices.Length; ind++)
                officeMapTiles[ind] = new MapTile(TYPE.COMPANY, DIRECTION.INTERSECTION) { SpriteBitmap = offices[ind] };

            busStopMapTiles = new MapTile[15];
            for (int ind = 0; ind < 15; ind++ )
                busStopMapTiles[ind] = new MapTile(TYPE.BUS_STOP, (DIRECTION)ind);

            mapTiles = new MapTile[15];
            for (int ind = 0; ind < 15; ind++)
                mapTiles[ind] = new MapTile(TYPE.ROAD, (DIRECTION)ind);
        }
Exemple #2
0
 /// <summary>
 /// Create a map square of the requested type. no road
 /// </summary>
 /// <param name="type">The square type.</param>
 public MapSquare(MapTile.TYPE type)
 {
     Tile = MapTile.Factory(type, MapTile.DIRECTION.INTERSECTION);
 }