diff options
Diffstat (limited to 'src/main/java/gtPlusPlus/everglades/biome')
4 files changed, 44 insertions, 31 deletions
diff --git a/src/main/java/gtPlusPlus/everglades/biome/BiomeGenerator_Custom.java b/src/main/java/gtPlusPlus/everglades/biome/BiomeGenerator_Custom.java index f443a6560d..2ea16a553a 100644 --- a/src/main/java/gtPlusPlus/everglades/biome/BiomeGenerator_Custom.java +++ b/src/main/java/gtPlusPlus/everglades/biome/BiomeGenerator_Custom.java @@ -3,9 +3,8 @@ package gtPlusPlus.everglades.biome; import static net.minecraftforge.event.terraingen.DecorateBiomeEvent.Decorate.EventType.*; import static net.minecraftforge.event.terraingen.OreGenEvent.GenerateMinable.EventType.*; -import gtPlusPlus.everglades.gen.WorldGenDeadLilly; -import gtPlusPlus.everglades.gen.WorldGenMinable_Custom; import java.util.Random; + import net.minecraft.block.BlockFlower; import net.minecraft.block.material.Material; import net.minecraft.init.Blocks; @@ -18,6 +17,9 @@ import net.minecraftforge.event.terraingen.DecorateBiomeEvent; import net.minecraftforge.event.terraingen.OreGenEvent; import net.minecraftforge.event.terraingen.TerrainGen; +import gtPlusPlus.everglades.gen.WorldGenDeadLilly; +import gtPlusPlus.everglades.gen.WorldGenMinable_Custom; + public class BiomeGenerator_Custom extends BiomeDecorator { public WorldGenerator fluoriteGen; @@ -57,8 +59,8 @@ public class BiomeGenerator_Custom extends BiomeDecorator { } @Override - public void decorateChunk( - World p_150512_1_, Random p_150512_2_, BiomeGenBase p_150512_3_, int p_150512_4_, int p_150512_5_) { + public void decorateChunk(World p_150512_1_, Random p_150512_2_, BiomeGenBase p_150512_3_, int p_150512_4_, + int p_150512_5_) { if (this.currentWorld != null) { throw new RuntimeException("Already decorating!!"); } else { @@ -85,7 +87,11 @@ public class BiomeGenerator_Custom extends BiomeDecorator { j = this.chunk_X + this.randomGenerator.nextInt(16) + 8; k = this.chunk_Z + this.randomGenerator.nextInt(16) + 8; this.sandGen.generate( - this.currentWorld, this.randomGenerator, j, this.currentWorld.getTopSolidOrLiquidBlock(j, k), k); + this.currentWorld, + this.randomGenerator, + j, + this.currentWorld.getTopSolidOrLiquidBlock(j, k), + k); } doGen = TerrainGen.decorate(currentWorld, randomGenerator, chunk_X, chunk_Z, CLAY); @@ -93,7 +99,11 @@ public class BiomeGenerator_Custom extends BiomeDecorator { j = this.chunk_X + this.randomGenerator.nextInt(16) + 8; k = this.chunk_Z + this.randomGenerator.nextInt(16) + 8; this.clayGen.generate( - this.currentWorld, this.randomGenerator, j, this.currentWorld.getTopSolidOrLiquidBlock(j, k), k); + this.currentWorld, + this.randomGenerator, + j, + this.currentWorld.getTopSolidOrLiquidBlock(j, k), + k); } doGen = TerrainGen.decorate(currentWorld, randomGenerator, chunk_X, chunk_Z, SAND_PASS2); @@ -101,7 +111,11 @@ public class BiomeGenerator_Custom extends BiomeDecorator { j = this.chunk_X + this.randomGenerator.nextInt(16) + 8; k = this.chunk_Z + this.randomGenerator.nextInt(16) + 8; this.gravelAsSandGen.generate( - this.currentWorld, this.randomGenerator, j, this.currentWorld.getTopSolidOrLiquidBlock(j, k), k); + this.currentWorld, + this.randomGenerator, + j, + this.currentWorld.getTopSolidOrLiquidBlock(j, k), + k); } i = this.treesPerChunk; @@ -130,8 +144,8 @@ public class BiomeGenerator_Custom extends BiomeDecorator { for (j = 0; doGen && j < this.bigMushroomsPerChunk; ++j) { k = this.chunk_X + this.randomGenerator.nextInt(16) + 8; l = this.chunk_Z + this.randomGenerator.nextInt(16) + 8; - this.bigMushroomGen.generate( - this.currentWorld, this.randomGenerator, k, this.currentWorld.getHeightValue(k, l), l); + this.bigMushroomGen + .generate(this.currentWorld, this.randomGenerator, k, this.currentWorld.getHeightValue(k, l), l); } doGen = TerrainGen.decorate(currentWorld, randomGenerator, chunk_X, chunk_Z, FLOWERS); @@ -170,9 +184,8 @@ public class BiomeGenerator_Custom extends BiomeDecorator { k = this.chunk_X + this.randomGenerator.nextInt(16) + 8; l = this.chunk_Z + this.randomGenerator.nextInt(16) + 8; - for (i1 = nextInt(this.currentWorld.getHeightValue(k, l) * 2); - i1 > 0 && this.currentWorld.isAirBlock(k, i1 - 1, l); - --i1) { + for (i1 = nextInt(this.currentWorld.getHeightValue(k, l) * 2); i1 > 0 + && this.currentWorld.isAirBlock(k, i1 - 1, l); --i1) { ; } @@ -252,8 +265,8 @@ public class BiomeGenerator_Custom extends BiomeDecorator { for (j = 0; j < 20; ++j) { k = this.chunk_X + this.randomGenerator.nextInt(16) + 8; - l = this.randomGenerator.nextInt( - this.randomGenerator.nextInt(this.randomGenerator.nextInt(240) + 8) + 8); + l = this.randomGenerator + .nextInt(this.randomGenerator.nextInt(this.randomGenerator.nextInt(240) + 8) + 8); i1 = this.chunk_Z + this.randomGenerator.nextInt(16) + 8; (new WorldGenLiquids(Blocks.flowing_lava)).generate(this.currentWorld, this.randomGenerator, k, l, i1); } @@ -282,8 +295,7 @@ public class BiomeGenerator_Custom extends BiomeDecorator { protected void genStandardOre2(int p_76793_1_, WorldGenerator p_76793_2_, int p_76793_3_, int p_76793_4_) { for (int l = 0; l < p_76793_1_; ++l) { int i1 = this.chunk_X + this.randomGenerator.nextInt(16); - int j1 = this.randomGenerator.nextInt(p_76793_4_) - + this.randomGenerator.nextInt(p_76793_4_) + int j1 = this.randomGenerator.nextInt(p_76793_4_) + this.randomGenerator.nextInt(p_76793_4_) + (p_76793_3_ - p_76793_4_); int k1 = this.chunk_Z + this.randomGenerator.nextInt(16); p_76793_2_.generate(this.currentWorld, this.randomGenerator, i1, j1, k1); diff --git a/src/main/java/gtPlusPlus/everglades/biome/Biome_Everglades.java b/src/main/java/gtPlusPlus/everglades/biome/Biome_Everglades.java index 918393bb8f..940c7b5a34 100644 --- a/src/main/java/gtPlusPlus/everglades/biome/Biome_Everglades.java +++ b/src/main/java/gtPlusPlus/everglades/biome/Biome_Everglades.java @@ -1,17 +1,8 @@ package gtPlusPlus.everglades.biome; -import cpw.mods.fml.common.event.FMLPreInitializationEvent; -import cpw.mods.fml.common.event.FMLServerStartingEvent; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; -import gtPlusPlus.api.objects.Logger; -import gtPlusPlus.core.entity.monster.EntitySickBlaze; -import gtPlusPlus.core.entity.monster.EntityStaballoyConstruct; -import gtPlusPlus.core.lib.CORE; -import gtPlusPlus.core.util.reflect.ReflectionUtils; -import gtPlusPlus.everglades.dimension.Dimension_Everglades; import java.lang.reflect.Field; import java.util.Random; + import net.minecraft.entity.monster.EntityPigZombie; import net.minecraft.entity.passive.EntityBat; import net.minecraft.entity.passive.EntitySquid; @@ -21,6 +12,17 @@ import net.minecraft.world.biome.BiomeGenBase; import net.minecraftforge.common.BiomeDictionary; import net.minecraftforge.common.BiomeManager; +import cpw.mods.fml.common.event.FMLPreInitializationEvent; +import cpw.mods.fml.common.event.FMLServerStartingEvent; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import gtPlusPlus.api.objects.Logger; +import gtPlusPlus.core.entity.monster.EntitySickBlaze; +import gtPlusPlus.core.entity.monster.EntityStaballoyConstruct; +import gtPlusPlus.core.lib.CORE; +import gtPlusPlus.core.util.reflect.ReflectionUtils; +import gtPlusPlus.everglades.dimension.Dimension_Everglades; + public class Biome_Everglades { public static BiomeGenEverglades biome = new BiomeGenEverglades(); @@ -49,6 +51,7 @@ public class Biome_Everglades { public void preInit(FMLPreInitializationEvent event) {} static class BiomeGenEverglades extends BiomeGenBase { + @SuppressWarnings("unchecked") public BiomeGenEverglades() { super(CORE.EVERGLADESBIOME_ID); @@ -115,7 +118,7 @@ public class Biome_Everglades { return 0xF67A14; } - @SuppressWarnings({"unchecked", "unused"}) + @SuppressWarnings({ "unchecked", "unused" }) private boolean addToMonsterSpawnLists(Class<?> EntityClass, int a, int b, int c) { // this.spawnableMonsterList.add(new SpawnListEntry(EntityClass, a, b, c)); this.spawnableCaveCreatureList.add(new SpawnListEntry(EntityClass, a, b, c)); diff --git a/src/main/java/gtPlusPlus/everglades/biome/GenLayerBiomes.java b/src/main/java/gtPlusPlus/everglades/biome/GenLayerBiomes.java index 9a84d6cc99..93c8404bb6 100644 --- a/src/main/java/gtPlusPlus/everglades/biome/GenLayerBiomes.java +++ b/src/main/java/gtPlusPlus/everglades/biome/GenLayerBiomes.java @@ -6,9 +6,7 @@ import net.minecraft.world.gen.layer.IntCache; public class GenLayerBiomes extends GenLayer { - protected BiomeGenBase[] allowedBiomes = { - Biome_Everglades.biome, - }; + protected BiomeGenBase[] allowedBiomes = { Biome_Everglades.biome, }; public GenLayerBiomes(long seed) { super(seed); diff --git a/src/main/java/gtPlusPlus/everglades/biome/GenLayerEverglades.java b/src/main/java/gtPlusPlus/everglades/biome/GenLayerEverglades.java index 59b4924355..dec0ed1429 100644 --- a/src/main/java/gtPlusPlus/everglades/biome/GenLayerEverglades.java +++ b/src/main/java/gtPlusPlus/everglades/biome/GenLayerEverglades.java @@ -22,7 +22,7 @@ public class GenLayerEverglades extends GenLayer { GenLayer genlayervoronoizoom = new GenLayerVoronoiZoom(10L, biomes); biomes.initWorldGenSeed(seed); genlayervoronoizoom.initWorldGenSeed(seed); - return new GenLayer[] {biomes, genlayervoronoizoom}; + return new GenLayer[] { biomes, genlayervoronoizoom }; } @Override |