From cede836d598680eac2ed2d2f0e3d5d5f8d4dab8b Mon Sep 17 00:00:00 2001 From: Matt Caughey Date: Thu, 22 May 2014 12:21:36 -0400 Subject: [PATCH] Changed the amount of BOP biomes that villages spawn in to be the same percentage as vanilla --- .../overworld/BiomeGenTropicalRainforest.java | 4 +- .../structures/BOPConfigurationVillages.java | 53 +- .../world/VillageMaterialEventHandler.java | 635 +----------------- 3 files changed, 4 insertions(+), 688 deletions(-) diff --git a/src/main/java/biomesoplenty/common/biomes/overworld/BiomeGenTropicalRainforest.java b/src/main/java/biomesoplenty/common/biomes/overworld/BiomeGenTropicalRainforest.java index 45c5b6190..70494fb84 100644 --- a/src/main/java/biomesoplenty/common/biomes/overworld/BiomeGenTropicalRainforest.java +++ b/src/main/java/biomesoplenty/common/biomes/overworld/BiomeGenTropicalRainforest.java @@ -93,14 +93,14 @@ public class BiomeGenTropicalRainforest extends BOPBiome public int getBiomeGrassColor(int x, int y, int z) { double d0 = plantNoise.func_151601_a((double)x * 0.0225D, (double)z * 0.0225D); - return d0 < -0.1D ? 11002176 : 11653451; + return d0 < -0.1D ? 11002176 : 12836929; } @Override public int getBiomeFoliageColor(int x, int y, int z) { double d0 = plantNoise.func_151601_a((double)x * 0.0225D, (double)z * 0.0225D); - return d0 < -0.1D ? 8970560 : 10080587; + return d0 < -0.1D ? 8970560 : 10870849; } @Override diff --git a/src/main/java/biomesoplenty/common/configuration/structures/BOPConfigurationVillages.java b/src/main/java/biomesoplenty/common/configuration/structures/BOPConfigurationVillages.java index 5fc38ce1f..19ab95bec 100644 --- a/src/main/java/biomesoplenty/common/configuration/structures/BOPConfigurationVillages.java +++ b/src/main/java/biomesoplenty/common/configuration/structures/BOPConfigurationVillages.java @@ -25,71 +25,20 @@ public class BOPConfigurationVillages public static void addDefaultVillageBiomes() { - //addVillageBiome(BOPCBiomes.alps); addVillageBiome(BOPCBiomes.arctic); - //addVillageBiome(BOPCBiomes.autumnHills); - //addVillageBiome(BOPCBiomes.badlands); - //addVillageBiome(BOPCBiomes.bambooForest); - addVillageBiome(BOPCBiomes.bayou); - addVillageBiome(BOPCBiomes.bog); - //addVillageBiome(BOPCBiomes.borealForest); addVillageBiome(BOPCBiomes.brushland); - addVillageBiome(BOPCBiomes.canyon); addVillageBiome(BOPCBiomes.chaparral); - //addVillageBiome(BOPCBiomes.cherryBlossomGrove); - addVillageBiome(BOPCBiomes.coniferousForest); - addVillageBiome(BOPCBiomes.snowyConiferousForest); addVillageBiome(BOPCBiomes.deadForest); - //addVillageBiome(BOPCBiomes.deadForestSnow); - //addVillageBiome(BOPCBiomes.deadSwamp); - addVillageBiome(BOPCBiomes.deciduousForest); - //addVillageBiome(BOPCBiomes.fen); - //addVillageBiome(BOPCBiomes.flowerField); addVillageBiome(BOPCBiomes.frostForest); - //addVillageBiome(BOPCBiomes.glacier); addVillageBiome(BOPCBiomes.grassland); addVillageBiome(BOPCBiomes.grove); addVillageBiome(BOPCBiomes.heathland); - //addVillageBiome(BOPCBiomes.highland); - //addVillageBiome(BOPCBiomes.hotSprings); - //addVillageBiome(BOPCBiomes.jadeCliffs); - //addVillageBiome(BOPCBiomes.lushDesert); - addVillageBiome(BOPCBiomes.lushSwamp); - //addVillageBiome(BOPCBiomes.mangrove); - addVillageBiome(BOPCBiomes.mapleWoods); - //addVillageBiome(BOPCBiomes.marsh); addVillageBiome(BOPCBiomes.meadow); - //addVillageBiome(BOPCBiomes.meadowForest); - //addVillageBiome(BOPCBiomes.mesa); - //addVillageBiome(BOPCBiomes.moor); - //addVillageBiome(BOPCBiomes.mountain); - //addVillageBiome(BOPCBiomes.oasis); - - //addVillageBiome(BOPCBiomes.orchard); addVillageBiome(BOPCBiomes.outback); - //addVillageBiome(BOPCBiomes.overgrownGreens); - //addVillageBiome(BOPCBiomes.polar); addVillageBiome(BOPCBiomes.prairie); - //addVillageBiome(BOPCBiomes.quagmire); - //addVillageBiome(BOPCBiomes.rainforest); - //addVillageBiome(BOPCBiomes.redwoodForest); - - addVillageBiome(BOPCBiomes.seasonalForest); - //addVillageBiome(BOPCBiomes.shield); - //addVillageBiome(BOPCBiomes.scrubland); addVillageBiome(BOPCBiomes.shrubland); - //addVillageBiome(BOPCBiomes.sludgepit); - addVillageBiome(BOPCBiomes.spruceWoods); - //addVillageBiome(BOPCBiomes.steppe); - //addVillageBiome(BOPCBiomes.temperateRainforest); - //addVillageBiome(BOPCBiomes.thicket); - //addVillageBiome(BOPCBiomes.tropicalRainforest); - //addVillageBiome(BOPCBiomes.tropics); + addVillageBiome(BOPCBiomes.steppe); addVillageBiome(BOPCBiomes.tundra); - //addVillageBiome(BOPCBiomes.volcano); - - //addVillageBiome(BOPCBiomes.wetland); - addVillageBiome(BOPCBiomes.woodland); } public static void init(File configFile) diff --git a/src/main/java/biomesoplenty/common/eventhandler/world/VillageMaterialEventHandler.java b/src/main/java/biomesoplenty/common/eventhandler/world/VillageMaterialEventHandler.java index b3821407a..7a6ce9654 100644 --- a/src/main/java/biomesoplenty/common/eventhandler/world/VillageMaterialEventHandler.java +++ b/src/main/java/biomesoplenty/common/eventhandler/world/VillageMaterialEventHandler.java @@ -13,17 +13,6 @@ public class VillageMaterialEventHandler @SubscribeEvent public void getVillageBlockID(BiomeEvent.GetVillageBlockID event) { - //Birch Forest - /*if (event.biome == Biomes.birchForest.get()) - { - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = Block.stairsWoodBirch.blockID; - event.setResult(Result.DENY); - } - }*/ - //Brushland if (event.biome == BOPCBiomes.brushland) { @@ -35,77 +24,6 @@ public class VillageMaterialEventHandler } } - //Coniferous Forest - if (event.biome == BOPCBiomes.coniferousForest) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = BOPBlockHelper.get("logs1"); - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = BOPBlockHelper.get("planks"); - event.setResult(Result.DENY); - } - - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = BOPBlockHelper.get("firStairs"); - event.setResult(Result.DENY); - } - } - - //Desert - /*if (event.biome == Biomes.desertNew.get()) - { - //Cobblestone - if (event.original == Blocks.cobblestone) - { - event.replacement = Block.sandStone.blockID; - event.setResult(Result.DENY); - } - - //Logs - if (event.original == Blocks.log) - { - event.replacement = Block.sandStone.blockID; - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = Block.sandStone.blockID; - event.setResult(Result.DENY); - } - - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = Block.stairsSandStone.blockID; - event.setResult(Result.DENY); - } - - //Cobblestone Stairs - if (event.original == Blocks.stone_brick_stairs) - { - event.replacement = Block.stairsSandStone.blockID; - event.setResult(Result.DENY); - } - - //Gravel - if (event.original == Blocks.gravel) - { - event.replacement = Block.sandStone.blockID; - event.setResult(Result.DENY); - } - }*/ - //Grove if (event.biome == BOPCBiomes.grove) { @@ -149,42 +67,6 @@ public class VillageMaterialEventHandler } } - //Lush Desert - if (event.biome == BOPCBiomes.lushDesert) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = Blocks.log2; - event.setResult(Result.DENY); - } - - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = Blocks.acacia_stairs; - event.setResult(Result.DENY); - } - - //Gravel - if (event.original == Blocks.gravel) - { - event.replacement = Blocks.sand; - event.setResult(Result.DENY); - } - } - - //Maple Woods - if (event.biome == BOPCBiomes.mapleWoods) - { - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = Blocks.spruce_stairs; - event.setResult(Result.DENY); - } - } - //Meadow if (event.biome == BOPCBiomes.meadow) { @@ -196,57 +78,6 @@ public class VillageMaterialEventHandler } } - //Meadow Forest - /*if (event.biome == Biomes.meadowForest.get()) - { - //Cobblestone - if (event.original == Blocks.cobblestone) - { - event.replacement = Blocks.log; - event.setResult(Result.DENY); - } - - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = Blocks.spruce_stairs; - event.setResult(Result.DENY); - } - - //Cobblestone Stairs - if (event.original == Blocks.stone_brick_stairs) - { - event.replacement = Blocks.spruce_stairs; - event.setResult(Result.DENY); - } - - //Stone Slabs - if (event.original == Blocks.stone_slab) - { - event.replacement = Blocks.wooden_slab; - event.setResult(Result.DENY); - } - - //Lava - if (event.original == Blocks.lava) - { - event.replacement = Blocks.water; - event.setResult(Result.DENY); - } - if (event.original == Blocks.flowing_lava) - { - event.replacement = Blocks.flowing_water; - event.setResult(Result.DENY); - } - - //Glass Panes - if (event.original == Blocks.glass_pane) - { - event.replacement = Blocks.iron_bars; - event.setResult(Result.DENY); - } - }*/ - //Outback if (event.biome == BOPCBiomes.outback) { @@ -279,31 +110,6 @@ public class VillageMaterialEventHandler } } - //Overgrown Greens - /*if (event.biome == Biomes.overgrownGreens.get()) - { - //Cobblestone - if (event.original == Blocks.cobblestone) - { - event.replacement = Blocks.mossy_cobblestone; - event.setResult(Result.DENY); - } - - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = Blocks.leaves; - event.setResult(Result.DENY); - } - - //Gravel - if (event.original == Blocks.gravel) - { - event.replacement = Blocks.grass; - event.setResult(Result.DENY); - } - }*/ - //Prairie if (event.biome == BOPCBiomes.prairie) { @@ -314,306 +120,11 @@ public class VillageMaterialEventHandler event.setResult(Result.DENY); } } - - //Savanna - /*if (event.biome == Biomes.savanna.get()) - { - //Cobblestone - if (event.original == Blocks.cobblestone) - { - event.replacement = BOPBlockHelper.get("logs1"); - event.setResult(Result.DENY); - } - - //Logs - if (event.original == Blocks.log) - { - event.replacement = BOPBlockHelper.get("logs1"); - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = BOPBlockHelper.get("planks"); - event.setResult(Result.DENY); - } - - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = Blocks.acacia_stairs; - event.setResult(Result.DENY); - } - - //Cobblestone Stairs - if (event.original == Blocks.stone_brick_stairs) - { - event.replacement = Blocks.acacia_stairs; - event.setResult(Result.DENY); - } - - //Stone Slabs - if (event.original == Blocks.stone_slab) - { - event.replacement = BOPBlockHelper.get("woodenSingleSlab1"); - event.setResult(Result.DENY); - } - - //Lava - if (event.original == Blocks.lava) - { - event.replacement = Blocks.water; - event.setResult(Result.DENY); - } - if (event.original == Blocks.flowing_lava) - { - event.replacement = Blocks.flowing_water; - event.setResult(Result.DENY); - } - - //Gravel - if (event.original == Blocks.gravel) - { - event.replacement = Blocks.sand; - event.setResult(Result.DENY); - } - - //Glass Panes - if (event.original == Blocks.glass_pane) - { - event.replacement = Blocks.iron_bars; - event.setResult(Result.DENY); - } - }*/ - - //Scrubland - /*if (event.biome == Biomes.scrubland.get()) - { - //Gravel - if (event.original == Blocks.gravel) - { - event.replacement = Blocks.sand; - event.setResult(Result.DENY); - } - }*/ - - //Snowy Coniferous Forest - if (event.biome == BOPCBiomes.snowyConiferousForest) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = BOPBlockHelper.get("logs1"); - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = BOPBlockHelper.get("planks"); - event.setResult(Result.DENY); - } - - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = BOPBlockHelper.get("firStairs"); - event.setResult(Result.DENY); - } - } - - //Spruce Woods - if (event.biome == BOPCBiomes.spruceWoods) - { - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = Blocks.spruce_stairs; - event.setResult(Result.DENY); - } - } - - //Steppe - /*if (event.biome == BOPBiomeHelper.get("steppe")) - { - //Cobblestone - if (event.original == Blocks.cobblestone) - { - event.replacement = BOPBlockHelper.get("logs1"); - event.setResult(Result.DENY); - } - - //Logs - if (event.original == Blocks.log) - { - event.replacement = BOPBlockHelper.get("logs1"); - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = BOPBlockHelper.get("planks"); - event.setResult(Result.DENY); - } - - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = Blocks.acacia_stairs; - event.setResult(Result.DENY); - } - - //Cobblestone Stairs - if (event.original == Blocks.stone_brick_stairs) - { - event.replacement = Blocks.acacia_stairs; - event.setResult(Result.DENY); - } - - //Stone Slabs - if (event.original == Blocks.stone_slab) - { - event.replacement = BOPBlockHelper.get("woodenSingleSlab1"); - event.setResult(Result.DENY); - } - - //Lava - if (event.original == Blocks.lava) - { - event.replacement = Blocks.water; - event.setResult(Result.DENY); - } - if (event.original == Blocks.flowing_lava) - { - event.replacement = Blocks.flowing_water; - event.setResult(Result.DENY); - } - - //Gravel - if (event.original == Blocks.gravel) - { - event.replacement = Blocks.sand; - event.setResult(Result.DENY); - } - - //Glass Panes - if (event.original == Blocks.glass_pane) - { - event.replacement = Blocks.iron_bars; - event.setResult(Result.DENY); - } - }*/ - - //Tropical Rainforest - if (event.biome == BOPCBiomes.tropicalRainforest) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = BOPBlockHelper.get("logs4"); - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = BOPBlockHelper.get("planks"); - event.setResult(Result.DENY); - } - - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = BOPBlockHelper.get("mahoganyStairs"); - event.setResult(Result.DENY); - } - - //Gravel - if (event.original == Blocks.gravel) - { - event.replacement = Blocks.sand; - event.setResult(Result.DENY); - } - } - - //Wetland - if (event.biome == BOPCBiomes.wetland) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = BOPBlockHelper.get("logs3"); - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = BOPBlockHelper.get("planks"); - event.setResult(Result.DENY); - } - - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = BOPBlockHelper.get("willowStairs"); - event.setResult(Result.DENY); - } - } } @SubscribeEvent public void getVillageBlockMeta(BiomeEvent.GetVillageBlockMeta event) - { - //Birch Forest - /*if (event.biome == Biomes.birchForest.get()) - { - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = 2; - event.setResult(Result.DENY); - } - }*/ - - //Coniferous Forest - if (event.biome == BOPCBiomes.coniferousForest) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = 3; - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = 3; - event.setResult(Result.DENY); - } - } - - //Desert - /*if (event.biome == Biomes.desertNew.get()) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = 0; - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = 2; - event.setResult(Result.DENY); - } - }*/ - + { //Grove if (event.biome == BOPCBiomes.grove) { @@ -657,35 +168,6 @@ public class VillageMaterialEventHandler } } - //Lush Desert - if (event.biome == BOPCBiomes.lushDesert) - { - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = 4; - event.setResult(Result.DENY); - } - } - - //Maple Woods - if (event.biome == BOPCBiomes.mapleWoods) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = 1; - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = 1; - event.setResult(Result.DENY); - } - } - //Meadow if (event.biome == BOPCBiomes.meadow) { @@ -704,38 +186,6 @@ public class VillageMaterialEventHandler } } - //Meadow Forest - /*if (event.biome == Biomes.meadowForest.get()) - { - //Cobblestone - if (event.original == Blocks.cobblestone) - { - event.replacement = 1; - event.setResult(Result.DENY); - } - - //Logs - if (event.original == Blocks.log) - { - event.replacement = 1; - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = 1; - event.setResult(Result.DENY); - } - - //Single Stone Slab - if (event.original == Blocks.stone_slab) - { - event.replacement = 1; - event.setResult(Result.DENY); - } - }*/ - //Outback if (event.biome == BOPCBiomes.outback) { @@ -746,88 +196,5 @@ public class VillageMaterialEventHandler event.setResult(Result.DENY); } } - - //Overgrown Greens - /*if (event.biome == Biomes.overgrownGreens.get()) - { - //Wooden Stairs - if (event.original == Blocks.oak_stairs) - { - event.replacement = 4; - event.setResult(Result.DENY); - } - }*/ - - //Snowy Coniferous Forest - if (event.biome == BOPCBiomes.snowyConiferousForest) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = 3; - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = 3; - event.setResult(Result.DENY); - } - } - - //Spruce Woods - if (event.biome == BOPCBiomes.spruceWoods) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = 1; - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = 1; - event.setResult(Result.DENY); - } - } - - //Tropical Rainforest - if (event.biome == BOPCBiomes.tropicalRainforest) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = 3; - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = 14; - event.setResult(Result.DENY); - } - } - - //Wetland - if (event.biome == BOPCBiomes.wetland) - { - //Logs - if (event.original == Blocks.log) - { - event.replacement = 1; - event.setResult(Result.DENY); - } - - //Wooden Planks - if (event.original == Blocks.planks) - { - event.replacement = 9; - event.setResult(Result.DENY); - } - } } } \ No newline at end of file