Package me.daddychurchill.CityWorld.Context

Source Code of me.daddychurchill.CityWorld.Context.IndustrialContext

package me.daddychurchill.CityWorld.Context;

import me.daddychurchill.CityWorld.WorldGenerator;
import me.daddychurchill.CityWorld.Clipboard.PasteProvider.SchematicFamily;
import me.daddychurchill.CityWorld.Plats.PlatLot;
import me.daddychurchill.CityWorld.Plats.Urban.StorageLot;
import me.daddychurchill.CityWorld.Plats.Urban.WarehouseBuildingLot;
import me.daddychurchill.CityWorld.Support.Odds;
import me.daddychurchill.CityWorld.Support.PlatMap;

public class IndustrialContext extends UrbanContext {

  public IndustrialContext(WorldGenerator generator) {
    super(generator);

    oddsOfParks = Odds.oddsUnlikely;
    oddsOfIsolatedLots = Odds.oddsPrettyUnlikely;
    oddsOfIdenticalBuildingHeights = Odds.oddsAlwaysGoingToHappen;
    oddsOfSimilarBuildingHeights = Odds.oddsExtremelyLikely;
    oddsOfSimilarBuildingRounding = Odds.oddsNeverGoingToHappen;
    oddsOfUnfinishedBuildings = Odds.oddsNeverGoingToHappen;
    oddsOfOnlyUnfinishedBasements = Odds.oddsNeverGoingToHappen;
    //oddsOfMissingRoad = oddsNeverGoingToHappen;
    oddsOfRoundAbouts = Odds.oddsUnlikely;
    
    oddsOfStairWallMaterialIsWallMaterial = Odds.oddsExtremelyLikely;
    oddsOfBuildingWallInset = Odds.oddsExtremelyLikely;
    oddsOfFlatWalledBuildings = Odds.oddsExtremelyLikely;
    oddsOfSimilarInsetBuildings = Odds.oddsExtremelyLikely;
    rangeOfWallInset = 2;
   
    schematicFamily = SchematicFamily.INDUSTRIAL;

    maximumFloorsAbove = 2;
    maximumFloorsBelow = 1;
  }
 
  private final static double oddsOfStorageLot = Odds.oddsVeryLikely;
  private final static double oddsOfWarehouse = Odds.oddsVeryLikely;
 
  @Override
  protected PlatLot getPark(WorldGenerator generator, PlatMap platmap, Odds odds, int chunkX, int chunkZ) {
    if (odds.playOdds(oddsOfStorageLot))
      return new StorageLot(platmap, chunkX, chunkZ);
    else
      return super.getPark(generator, platmap, odds, chunkX, chunkZ);
  }
 
  @Override
  protected PlatLot getBuilding(WorldGenerator generator, PlatMap platmap, Odds odds, int chunkX, int chunkZ) {
    if (odds.playOdds(oddsOfWarehouse))
      return new WarehouseBuildingLot(platmap, chunkX, chunkZ);
    else
      return super.getBuilding(generator, platmap, odds, chunkX, chunkZ);
  }
}
TOP

Related Classes of me.daddychurchill.CityWorld.Context.IndustrialContext

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.