Exemplo n.º 1
0
 private GeoBlockComplex(GeoBlockFlat block) : base(block.getGeoX(), block.getGeoY())
 {
     _cells = new GeoCell[GeoEngine.GEO_BLOCK_SHIFT * GeoEngine.GEO_BLOCK_SHIFT];
     for (int x = 0, y; x < GeoEngine.GEO_BLOCK_SHIFT; x++)
     {
         for (y = 0; y < GeoEngine.GEO_BLOCK_SHIFT; y++)
         {
             _cells[indexOf(x, y)] = new GeoCellCM(this, GeoEngine.convertHeightToHeightAndNSWEALL(block.getMinHeight()), x, y);
         }
     }
     calcMaxMinHeight();
 }
 private GeoBlockMultiLayer(GeoBlockFlat block) : base(block.getGeoX(), block.getGeoY())
 {
     _cells3D = new GeoCell[GeoEngine.GEO_BLOCK_SHIFT, GeoEngine.GEO_BLOCK_SHIFT][];
     _cells   = new GeoCell[GeoEngine.GEO_BLOCK_SHIFT * GeoEngine.GEO_BLOCK_SHIFT];
     //
     for (int x = 0; x < GeoEngine.GEO_BLOCK_SHIFT; x++)
     {
         for (int y = 0; y < GeoEngine.GEO_BLOCK_SHIFT; y++)
         {
             GeoCell cell = new GeoCellCM(this, GeoEngine.convertHeightToHeightAndNSWEALL(block.getMinHeight()), x, y);
             _cells3D[x, y]    = new GeoCell[1];
             _cells3D[x, y][0] = cell;
             _cells[x * GeoEngine.GEO_BLOCK_SHIFT + y] = cell;
         }
     }
     calcMaxMinHeight();
 }