diff --git a/src/minecraft/biomesoplenty/ClientProxy.java b/src/minecraft/biomesoplenty/ClientProxy.java index a0d534e53..f03172b24 100644 --- a/src/minecraft/biomesoplenty/ClientProxy.java +++ b/src/minecraft/biomesoplenty/ClientProxy.java @@ -1,18 +1,12 @@ package biomesoplenty; -import net.minecraft.block.Block; import net.minecraft.client.Minecraft; import net.minecraft.client.model.ModelSlime; import net.minecraft.client.particle.EntityBreakingFX; import net.minecraft.client.particle.EntityFX; -import net.minecraft.client.renderer.RenderBlocks; -import net.minecraft.client.renderer.Tessellator; import net.minecraft.client.renderer.entity.RenderSnowball; import net.minecraftforge.fluids.FluidRegistry; import net.minecraftforge.fluids.RenderBlockFluid; - -import org.lwjgl.opengl.GL11; - import biomesoplenty.api.Items; import biomesoplenty.blocks.renderers.AltarRenderer; import biomesoplenty.blocks.renderers.FoliageRenderer; @@ -38,10 +32,13 @@ public class ClientProxy extends CommonProxy { public void registerRenderers() { RenderUtils.altarModel = RenderingRegistry.getNextAvailableRenderId(); + RenderUtils.foliageModel = RenderingRegistry.getNextAvailableRenderId();; + RenderUtils.plantsModel = RenderingRegistry.getNextAvailableRenderId();; + RenderUtils.puddleModel = RenderingRegistry.getNextAvailableRenderId();; + RenderUtils.bonesModel = RenderingRegistry.getNextAvailableRenderId();; RenderingRegistry.registerEntityRenderingHandler(EntityMudball.class, new RenderSnowball(Items.mudball.get(), 0)); RenderingRegistry.registerEntityRenderingHandler(EntityDart.class, new RenderDart()); - //RenderingRegistry.registerEntityRenderingHandler(EntityPoisonDart.class, new RenderPoisonDart()); RenderingRegistry.registerEntityRenderingHandler(EntityGlob.class, new RenderGlob(new ModelSlime(16), new ModelSlime(0), 0.25F)); diff --git a/src/minecraft/biomesoplenty/CommonProxy.java b/src/minecraft/biomesoplenty/CommonProxy.java index cb039eab7..dfed9325f 100644 --- a/src/minecraft/biomesoplenty/CommonProxy.java +++ b/src/minecraft/biomesoplenty/CommonProxy.java @@ -1,14 +1,8 @@ package biomesoplenty; -import net.minecraft.block.Block; -import net.minecraft.client.renderer.RenderBlocks; - -public class CommonProxy { - public static String ARMOR_MUD1_PNG = "/mods/BiomesOPlenty/textures/armor/mud_1.png"; - public static String ARMOR_MUD2_PNG = "/mods/BiomesOPlenty/textures/armor/mud_2.png"; - public static String ARMOR_AMETHYST1_PNG = "/mods/BiomesOPlenty/textures/armor/amethyst_1.png"; - public static String ARMOR_AMETHYST2_PNG = "/mods/BiomesOPlenty/textures/armor/amethyst_2.png"; +public class CommonProxy +{ // Client stuff public void registerRenderers() { // Nothing here as the server doesn't render graphics! diff --git a/src/minecraft/biomesoplenty/api/BlockReferences.java b/src/minecraft/biomesoplenty/api/BlockReferences.java index 0135819aa..beb7ab631 100644 --- a/src/minecraft/biomesoplenty/api/BlockReferences.java +++ b/src/minecraft/biomesoplenty/api/BlockReferences.java @@ -200,9 +200,11 @@ public class BlockReferences { int stackmeta = EnumBlocks.valueOf(string).meta; if (stackmeta != 0) + { return new ItemStack(stackblock.get(), 1, stackmeta); - else - return new ItemStack(stackblock.get(), 1); + } + + return new ItemStack(stackblock.get(), 1); } public static int getBlockID(String string) diff --git a/src/minecraft/biomesoplenty/armor/ArmorAmethyst.java b/src/minecraft/biomesoplenty/armor/ArmorAmethyst.java index 073d9f999..dfe927cf0 100644 --- a/src/minecraft/biomesoplenty/armor/ArmorAmethyst.java +++ b/src/minecraft/biomesoplenty/armor/ArmorAmethyst.java @@ -1,19 +1,19 @@ package biomesoplenty.armor; import net.minecraft.client.renderer.texture.IconRegister; +import net.minecraft.entity.Entity; import net.minecraft.item.EnumArmorMaterial; import net.minecraft.item.ItemArmor; import net.minecraft.item.ItemStack; -import net.minecraftforge.common.IArmorTextureProvider; import biomesoplenty.BiomesOPlenty; -import biomesoplenty.CommonProxy; import biomesoplenty.api.Items; -public class ArmorAmethyst extends ItemArmor implements IArmorTextureProvider +public class ArmorAmethyst extends ItemArmor { public int textureID = 0; - public ArmorAmethyst(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4) { + public ArmorAmethyst(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4) + { super(par1, par2EnumArmorMaterial, par3, par4); textureID = par4; setCreativeTab(BiomesOPlenty.tabBiomesOPlenty); @@ -24,26 +24,28 @@ public class ArmorAmethyst extends ItemArmor implements IArmorTextureProvider { if (par2ItemStack.itemID == Items.miscItems.get().itemID && par2ItemStack.getItemDamage() == 2) return true; - else - return false; + + return false; } @Override - public String getArmorTextureFile(ItemStack par1) { - if(par1.itemID == Items.helmetAmethyst.get().itemID||par1.itemID == Items.chestplateAmethyst.get().itemID||par1.itemID == Items.bootsAmethyst.get().itemID) - return CommonProxy.ARMOR_AMETHYST1_PNG; - if(par1.itemID == Items.leggingsAmethyst.get().itemID) - return CommonProxy.ARMOR_AMETHYST2_PNG; + public String getArmorTexture(ItemStack stack, Entity entity, int slot, int layer) + { + if (stack.itemID == Items.helmetAmethyst.get().itemID || stack.itemID == Items.chestplateAmethyst.get().itemID || stack.itemID == Items.bootsAmethyst.get().itemID) + return "/mods/BiomesOPlenty/textures/armor/amethyst_1.png"; + if (stack.itemID == Items.leggingsAmethyst.get().itemID) + return "/mods/BiomesOPlenty/textures/armor/amethyst_2.png"; + return null; } @Override public void registerIcons(IconRegister iconRegister) { - if(textureID==0){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethysthelmet"); } - else if(textureID==1){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethystchestplate"); } - else if(textureID==2){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethystleggings"); } - else if(textureID==3){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethystboots"); } + if (textureID == 0) { itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethysthelmet"); } + else if (textureID == 1) { itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethystchestplate"); } + else if (textureID == 2) { itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethystleggings"); } + else if (textureID == 3) { itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethystboots"); } else { itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudball"); } } } diff --git a/src/minecraft/biomesoplenty/armor/ArmorFlowerBand.java b/src/minecraft/biomesoplenty/armor/ArmorFlowerBand.java index 84b29b9d6..95d7450a6 100644 --- a/src/minecraft/biomesoplenty/armor/ArmorFlowerBand.java +++ b/src/minecraft/biomesoplenty/armor/ArmorFlowerBand.java @@ -4,15 +4,15 @@ import java.util.List; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.creativetab.CreativeTabs; +import net.minecraft.entity.Entity; import net.minecraft.item.EnumArmorMaterial; import net.minecraft.item.ItemArmor; import net.minecraft.item.ItemStack; import net.minecraft.util.Icon; -import net.minecraftforge.common.IArmorTextureProvider; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; -public class ArmorFlowerBand extends ItemArmor implements IArmorTextureProvider +public class ArmorFlowerBand extends ItemArmor { private static final String[] flowerBandTypes = new String[] {"dullflowerband", "plainflowerband", "lushflowerband", "exoticflowerband"}; @SideOnly(Side.CLIENT) @@ -58,18 +58,18 @@ public class ArmorFlowerBand extends ItemArmor implements IArmorTextureProvider } @Override - public String getArmorTextureFile(ItemStack par1) + public String getArmorTexture(ItemStack stack, Entity entity, int slot, int layer) { - if (par1.getItemDamage() == 0) + if (stack.getItemDamage() == 0) return "/mods/BiomesOPlenty/textures/armor/dullflowerband.png"; - if (par1.getItemDamage() == 1) + if (stack.getItemDamage() == 1) return "/mods/BiomesOPlenty/textures/armor/plainflowerband.png"; - if (par1.getItemDamage() == 2) + if (stack.getItemDamage() == 2) return "/mods/BiomesOPlenty/textures/armor/lushflowerband.png"; - if (par1.getItemDamage() == 3) + if (stack.getItemDamage() == 3) return "/mods/BiomesOPlenty/textures/armor/exoticflowerband.png"; return null; diff --git a/src/minecraft/biomesoplenty/armor/ArmorMuddy.java b/src/minecraft/biomesoplenty/armor/ArmorMuddy.java index e7d259c1f..bf526db68 100644 --- a/src/minecraft/biomesoplenty/armor/ArmorMuddy.java +++ b/src/minecraft/biomesoplenty/armor/ArmorMuddy.java @@ -1,40 +1,42 @@ package biomesoplenty.armor; import net.minecraft.client.renderer.texture.IconRegister; +import net.minecraft.entity.Entity; import net.minecraft.item.EnumArmorMaterial; import net.minecraft.item.ItemArmor; import net.minecraft.item.ItemStack; -import net.minecraftforge.common.IArmorTextureProvider; import biomesoplenty.BiomesOPlenty; -import biomesoplenty.CommonProxy; import biomesoplenty.api.Items; -public class ArmorMuddy extends ItemArmor implements IArmorTextureProvider +public class ArmorMuddy extends ItemArmor { public int textureID = 0; - public ArmorMuddy(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4) { + public ArmorMuddy(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4) + { super(par1, par2EnumArmorMaterial, par3, par4); textureID = par4; setCreativeTab(BiomesOPlenty.tabBiomesOPlenty); } @Override - public String getArmorTextureFile(ItemStack par1) { - if(par1.itemID == Items.helmetMud.get().itemID||par1.itemID == Items.chestplateMud.get().itemID||par1.itemID == Items.bootsMud.get().itemID) - return CommonProxy.ARMOR_MUD1_PNG; - if(par1.itemID == Items.leggingsMud.get().itemID) - return CommonProxy.ARMOR_MUD2_PNG; + public String getArmorTexture(ItemStack stack, Entity entity, int slot, int layer) + { + if (stack.itemID == Items.helmetMud.get().itemID || stack.itemID == Items.chestplateMud.get().itemID || stack.itemID == Items.bootsMud.get().itemID) + return "/mods/BiomesOPlenty/textures/armor/mud_1.png"; + if (stack.itemID == Items.leggingsMud.get().itemID) + return "/mods/BiomesOPlenty/textures/armor/mud_2.png"; + return null; } @Override public void registerIcons(IconRegister iconRegister) { - if(textureID==0){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudhelmet"); } - else if(textureID==1){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudchestplate"); } - else if(textureID==2){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudleggings"); } - else if(textureID==3){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudboots"); } + if (textureID == 0) { itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudhelmet"); } + else if (textureID == 1) { itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudchestplate"); } + else if (textureID == 2) { itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudleggings"); } + else if (textureID == 3) { itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudboots"); } else { itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudball"); } } } diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenAlps.java b/src/minecraft/biomesoplenty/biomes/BiomeGenAlps.java index 6aad74b10..f283856ae 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenAlps.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenAlps.java @@ -6,8 +6,8 @@ import net.minecraft.block.Block; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenerator; -import biomesoplenty.worldgen.WorldGenTaiga6; import biomesoplenty.api.Blocks; +import biomesoplenty.worldgen.WorldGenTaiga6; public class BiomeGenAlps extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenBadlands.java b/src/minecraft/biomesoplenty/biomes/BiomeGenBadlands.java index 5285941aa..993853f39 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenBadlands.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenBadlands.java @@ -1,7 +1,7 @@ package biomesoplenty.biomes; -import java.util.Random; import java.awt.Color; +import java.util.Random; import net.minecraft.block.Block; import net.minecraft.world.World; diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenBayou.java b/src/minecraft/biomesoplenty/biomes/BiomeGenBayou.java index 9ab2277f8..0af308005 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenBayou.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenBayou.java @@ -3,18 +3,18 @@ package biomesoplenty.biomes; import java.awt.Color; import java.util.Random; -import net.minecraft.entity.monster.EntitySlime; import net.minecraft.block.Block; +import net.minecraft.entity.monster.EntitySlime; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenerator; +import biomesoplenty.api.Blocks; import biomesoplenty.configuration.BOPConfiguration; import biomesoplenty.worldgen.WorldGenBayou1; import biomesoplenty.worldgen.WorldGenBayou2; import biomesoplenty.worldgen.WorldGenBayou3; import biomesoplenty.worldgen.WorldGenMoss; -import biomesoplenty.api.Blocks; public class BiomeGenBayou extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenBeachGravel.java b/src/minecraft/biomesoplenty/biomes/BiomeGenBeachGravel.java index af734b919..365211c8c 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenBeachGravel.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenBeachGravel.java @@ -1,11 +1,7 @@ package biomesoplenty.biomes; -import java.util.Random; - import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; -import biomesoplenty.api.Blocks; public class BiomeGenBeachGravel extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenBeachOvergrown.java b/src/minecraft/biomesoplenty/biomes/BiomeGenBeachOvergrown.java index 4348c9d2d..888712c4a 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenBeachOvergrown.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenBeachOvergrown.java @@ -3,12 +3,10 @@ package biomesoplenty.biomes; import java.util.Random; import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenerator; import biomesoplenty.worldgen.WorldGenChaparral2; import biomesoplenty.worldgen.WorldGenChaparral3; -import biomesoplenty.api.Blocks; public class BiomeGenBeachOvergrown extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenBorealForest.java b/src/minecraft/biomesoplenty/biomes/BiomeGenBorealForest.java index bc617be78..bf53fb2f5 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenBorealForest.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenBorealForest.java @@ -3,8 +3,8 @@ package biomesoplenty.biomes; import java.util.Random; import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.entity.passive.EntityWolf; +import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenShrub; diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenCrag.java b/src/minecraft/biomesoplenty/biomes/BiomeGenCrag.java index 422bd4fce..0b6a22fec 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenCrag.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenCrag.java @@ -1,7 +1,7 @@ package biomesoplenty.biomes; -import java.util.Random; import java.awt.Color; +import java.util.Random; import net.minecraft.block.Block; import net.minecraft.world.World; diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenDunes.java b/src/minecraft/biomesoplenty/biomes/BiomeGenDunes.java index d58766f21..af7b98f23 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenDunes.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenDunes.java @@ -1,13 +1,13 @@ package biomesoplenty.biomes; -import java.util.Random; import java.awt.Color; +import java.util.Random; import net.minecraft.block.Block; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; -import biomesoplenty.configuration.BOPConfiguration; import biomesoplenty.api.Blocks; +import biomesoplenty.configuration.BOPConfiguration; public class BiomeGenDunes extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenField.java b/src/minecraft/biomesoplenty/biomes/BiomeGenField.java index 94c48cb65..82de96625 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenField.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenField.java @@ -6,8 +6,8 @@ import net.minecraft.block.Block; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenerator; -import biomesoplenty.worldgen.WorldGenLargeTree; import biomesoplenty.api.Blocks; +import biomesoplenty.worldgen.WorldGenLargeTree; public class BiomeGenField extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenForestNew.java b/src/minecraft/biomesoplenty/biomes/BiomeGenForestNew.java index d5e86660e..b1e558d20 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenForestNew.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenForestNew.java @@ -2,8 +2,8 @@ package biomesoplenty.biomes; import java.util.Random; -import net.minecraft.entity.passive.EntityWolf; import net.minecraft.block.Block; +import net.minecraft.entity.passive.EntityWolf; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenFrostForest.java b/src/minecraft/biomesoplenty/biomes/BiomeGenFrostForest.java index 3d90c22ad..8f52f683d 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenFrostForest.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenFrostForest.java @@ -7,8 +7,8 @@ import net.minecraft.block.Block; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenerator; -import biomesoplenty.configuration.BOPConfiguration; import biomesoplenty.api.Blocks; +import biomesoplenty.configuration.BOPConfiguration; public class BiomeGenFrostForest extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenGarden.java b/src/minecraft/biomesoplenty/biomes/BiomeGenGarden.java index 30c509bf9..6862934c9 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenGarden.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenGarden.java @@ -8,10 +8,10 @@ import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenTallGrass; import net.minecraft.world.gen.feature.WorldGenerator; -import biomesoplenty.worldgen.WorldGenGiantFlowerRed; -import biomesoplenty.worldgen.WorldGenGiantFlowerYellow; import biomesoplenty.api.Blocks; import biomesoplenty.entities.EntityRosester; +import biomesoplenty.worldgen.WorldGenGiantFlowerRed; +import biomesoplenty.worldgen.WorldGenGiantFlowerYellow; public class BiomeGenGarden extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenHeathland.java b/src/minecraft/biomesoplenty/biomes/BiomeGenHeathland.java index 51d263215..b89898995 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenHeathland.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenHeathland.java @@ -7,8 +7,8 @@ import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenShrub; import net.minecraft.world.gen.feature.WorldGenerator; -import biomesoplenty.worldgen.WorldGenJacarandaShrub; import biomesoplenty.api.Blocks; +import biomesoplenty.worldgen.WorldGenJacarandaShrub; public class BiomeGenHeathland extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenHotSprings.java b/src/minecraft/biomesoplenty/biomes/BiomeGenHotSprings.java index a5ee25edb..ce60279d2 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenHotSprings.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenHotSprings.java @@ -6,9 +6,9 @@ import net.minecraft.block.Block; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenerator; +import biomesoplenty.api.Blocks; import biomesoplenty.worldgen.WorldGenPineTree; import biomesoplenty.worldgen.WorldGenTaiga6; -import biomesoplenty.api.Blocks; public class BiomeGenHotSprings extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenIcyHills.java b/src/minecraft/biomesoplenty/biomes/BiomeGenIcyHills.java index 18c7ed3e8..62d62849b 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenIcyHills.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenIcyHills.java @@ -4,14 +4,14 @@ import java.awt.Color; import java.util.Random; import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.entity.monster.EntitySnowman; +import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenerator; +import biomesoplenty.api.Blocks; import biomesoplenty.configuration.BOPConfiguration; import biomesoplenty.worldgen.WorldGenIceTree; -import biomesoplenty.api.Blocks; public class BiomeGenIcyHills extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenLushSwamp.java b/src/minecraft/biomesoplenty/biomes/BiomeGenLushSwamp.java index b8301aefb..0e1004446 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenLushSwamp.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenLushSwamp.java @@ -8,8 +8,8 @@ import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenerator; -import biomesoplenty.worldgen.WorldGenSwampTall; import biomesoplenty.api.Blocks; +import biomesoplenty.worldgen.WorldGenSwampTall; public class BiomeGenLushSwamp extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenMangrove.java b/src/minecraft/biomesoplenty/biomes/BiomeGenMangrove.java index 2c5b60510..e2f3e843a 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenMangrove.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenMangrove.java @@ -6,9 +6,9 @@ import net.minecraft.block.Block; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenerator; +import biomesoplenty.api.Blocks; import biomesoplenty.worldgen.WorldGenMangrove; import biomesoplenty.worldgen.WorldGenMangrove2; -import biomesoplenty.api.Blocks; public class BiomeGenMangrove extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenMesa.java b/src/minecraft/biomesoplenty/biomes/BiomeGenMesa.java index 3e304d1c9..b67b55665 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenMesa.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenMesa.java @@ -1,11 +1,11 @@ package biomesoplenty.biomes; -import java.util.Random; import java.awt.Color; +import java.util.Random; import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.entity.monster.EntitySpider; +import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import biomesoplenty.api.Blocks; diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenOasis.java b/src/minecraft/biomesoplenty/biomes/BiomeGenOasis.java index 126e679cc..b78cab700 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenOasis.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenOasis.java @@ -6,8 +6,8 @@ import net.minecraft.block.Block; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenerator; -import biomesoplenty.worldgen.WorldGenPalmTree3; import biomesoplenty.api.Blocks; +import biomesoplenty.worldgen.WorldGenPalmTree3; public class BiomeGenOasis extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenOrchard.java b/src/minecraft/biomesoplenty/biomes/BiomeGenOrchard.java index 854b28640..9da877465 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenOrchard.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenOrchard.java @@ -6,8 +6,8 @@ import net.minecraft.block.Block; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenerator; -import biomesoplenty.worldgen.WorldGenApple; import biomesoplenty.api.Blocks; +import biomesoplenty.worldgen.WorldGenApple; public class BiomeGenOrchard extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenRainforest.java b/src/minecraft/biomesoplenty/biomes/BiomeGenRainforest.java index 840d03a5f..3394257c2 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenRainforest.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenRainforest.java @@ -3,15 +3,15 @@ package biomesoplenty.biomes; import java.util.Random; import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.entity.passive.EntityOcelot; +import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenTallGrass; import net.minecraft.world.gen.feature.WorldGenerator; -import biomesoplenty.worldgen.WorldGenRainforestTree1; import biomesoplenty.api.Blocks; import biomesoplenty.entities.EntityJungleSpider; +import biomesoplenty.worldgen.WorldGenRainforestTree1; public class BiomeGenRainforest extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenSacredSprings.java b/src/minecraft/biomesoplenty/biomes/BiomeGenSacredSprings.java index 8295c490f..51c5e9cf7 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenSacredSprings.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenSacredSprings.java @@ -9,9 +9,9 @@ import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenShrub; import net.minecraft.world.gen.feature.WorldGenerator; +import biomesoplenty.api.Blocks; import biomesoplenty.configuration.BOPConfiguration; import biomesoplenty.entities.EntityJungleSpider; -import biomesoplenty.api.Blocks; public class BiomeGenSacredSprings extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenScrubland.java b/src/minecraft/biomesoplenty/biomes/BiomeGenScrubland.java index e4c207234..c5d28b004 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenScrubland.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenScrubland.java @@ -8,8 +8,8 @@ import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenShrub; import net.minecraft.world.gen.feature.WorldGenTallGrass; import net.minecraft.world.gen.feature.WorldGenerator; -import biomesoplenty.worldgen.WorldGenScrubland; import biomesoplenty.api.Blocks; +import biomesoplenty.worldgen.WorldGenScrubland; public class BiomeGenScrubland extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenSeasonalForest.java b/src/minecraft/biomesoplenty/biomes/BiomeGenSeasonalForest.java index ab2bedc5c..0c5d965f4 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenSeasonalForest.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenSeasonalForest.java @@ -3,8 +3,8 @@ package biomesoplenty.biomes; import java.util.Random; import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.entity.passive.EntityWolf; +import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenTallGrass; diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenSludgepit.java b/src/minecraft/biomesoplenty/biomes/BiomeGenSludgepit.java index 1f9133d56..c63749843 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenSludgepit.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenSludgepit.java @@ -4,8 +4,8 @@ import java.awt.Color; import java.util.Random; import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.entity.monster.EntitySlime; +import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenTallGrass; diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenSpruceWoods.java b/src/minecraft/biomesoplenty/biomes/BiomeGenSpruceWoods.java index 2adcf6b63..1777ad439 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenSpruceWoods.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenSpruceWoods.java @@ -3,8 +3,8 @@ package biomesoplenty.biomes; import java.util.Random; import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.entity.passive.EntityWolf; +import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenTaiga2; diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenSwampNew.java b/src/minecraft/biomesoplenty/biomes/BiomeGenSwampNew.java index 873d54ce5..73a755a33 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenSwampNew.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenSwampNew.java @@ -2,18 +2,18 @@ package biomesoplenty.biomes; import java.util.Random; +import net.minecraft.block.Block; import net.minecraft.entity.monster.EntitySlime; import net.minecraft.world.ColorizerFoliage; import net.minecraft.world.ColorizerGrass; -import net.minecraft.block.Block; import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenerator; +import biomesoplenty.api.Blocks; import biomesoplenty.worldgen.WorldGenLog; import biomesoplenty.worldgen.WorldGenMoss; import biomesoplenty.worldgen.WorldGenWillow; -import biomesoplenty.api.Blocks; public class BiomeGenSwampNew extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenTaigaNew.java b/src/minecraft/biomesoplenty/biomes/BiomeGenTaigaNew.java index 2323d329d..fef063912 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenTaigaNew.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenTaigaNew.java @@ -3,8 +3,8 @@ package biomesoplenty.biomes; import java.util.Random; import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.entity.passive.EntityWolf; +import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenTaiga1; diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenThicket.java b/src/minecraft/biomesoplenty/biomes/BiomeGenThicket.java index dd30c1be9..56fbace13 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenThicket.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenThicket.java @@ -2,8 +2,6 @@ package biomesoplenty.biomes; import java.util.Random; -import net.minecraft.block.Block; -import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.feature.WorldGenShrub; import net.minecraft.world.gen.feature.WorldGenerator; diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenTropicalRainforest.java b/src/minecraft/biomesoplenty/biomes/BiomeGenTropicalRainforest.java index 1345ae6b5..30ca43b95 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenTropicalRainforest.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenTropicalRainforest.java @@ -9,11 +9,11 @@ import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenerator; +import biomesoplenty.api.Blocks; import biomesoplenty.configuration.BOPConfiguration; import biomesoplenty.entities.EntityJungleSpider; import biomesoplenty.worldgen.WorldGenRainforest1; import biomesoplenty.worldgen.WorldGenRainforest2; -import biomesoplenty.api.Blocks; public class BiomeGenTropicalRainforest extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenTropics.java b/src/minecraft/biomesoplenty/biomes/BiomeGenTropics.java index 7938d8d26..fe6bbea39 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenTropics.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenTropics.java @@ -8,11 +8,11 @@ import net.minecraft.world.World; import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenerator; +import biomesoplenty.api.Blocks; import biomesoplenty.configuration.BOPConfiguration; import biomesoplenty.entities.EntityJungleSpider; import biomesoplenty.worldgen.WorldGenPalmTree1; import biomesoplenty.worldgen.WorldGenPalmTree3; -import biomesoplenty.api.Blocks; public class BiomeGenTropics extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenWetland.java b/src/minecraft/biomesoplenty/biomes/BiomeGenWetland.java index eb18fb4b4..ba2804c68 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenWetland.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenWetland.java @@ -9,10 +9,10 @@ import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.biome.SpawnListEntry; import net.minecraft.world.gen.feature.WorldGenTallGrass; import net.minecraft.world.gen.feature.WorldGenerator; +import biomesoplenty.api.Blocks; import biomesoplenty.worldgen.WorldGenMoss; import biomesoplenty.worldgen.WorldGenTaiga5; import biomesoplenty.worldgen.WorldGenWillow; -import biomesoplenty.api.Blocks; public class BiomeGenWetland extends BiomeGenBase { diff --git a/src/minecraft/biomesoplenty/blocks/BlockBOPFlower.java b/src/minecraft/biomesoplenty/blocks/BlockBOPFlower.java index 389b98958..e298b450e 100644 --- a/src/minecraft/biomesoplenty/blocks/BlockBOPFlower.java +++ b/src/minecraft/biomesoplenty/blocks/BlockBOPFlower.java @@ -19,7 +19,7 @@ import net.minecraft.world.IBlockAccess; import net.minecraft.world.World; import biomesoplenty.BiomesOPlenty; import biomesoplenty.api.Blocks; -import biomesoplenty.blocks.renderers.FoliageRenderer; +import biomesoplenty.blocks.renderers.RenderUtils; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; @@ -66,9 +66,9 @@ public class BlockBOPFlower extends BlockFlower } @Override - public int getRenderType () + public int getRenderType() { - return FoliageRenderer.render; + return RenderUtils.foliageModel; } @Override diff --git a/src/minecraft/biomesoplenty/blocks/BlockBOPFoliage.java b/src/minecraft/biomesoplenty/blocks/BlockBOPFoliage.java index 14552cf2c..fdfe90636 100644 --- a/src/minecraft/biomesoplenty/blocks/BlockBOPFoliage.java +++ b/src/minecraft/biomesoplenty/blocks/BlockBOPFoliage.java @@ -29,7 +29,7 @@ import net.minecraftforge.common.IShearable; import biomesoplenty.BiomesOPlenty; import biomesoplenty.api.Blocks; import biomesoplenty.api.Items; -import biomesoplenty.blocks.renderers.FoliageRenderer; +import biomesoplenty.blocks.renderers.RenderUtils; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; @@ -210,7 +210,7 @@ public class BlockBOPFoliage extends BlockFlower implements IShearable @Override public int getRenderType () { - return FoliageRenderer.render; + return RenderUtils.foliageModel; } @Override diff --git a/src/minecraft/biomesoplenty/blocks/BlockBOPGeneric.java b/src/minecraft/biomesoplenty/blocks/BlockBOPGeneric.java index ece3b0e25..b24bdf766 100644 --- a/src/minecraft/biomesoplenty/blocks/BlockBOPGeneric.java +++ b/src/minecraft/biomesoplenty/blocks/BlockBOPGeneric.java @@ -5,10 +5,8 @@ import java.util.Random; import net.minecraft.block.Block; import net.minecraft.block.material.Material; import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.item.ItemStack; import net.minecraft.util.Icon; import biomesoplenty.BiomesOPlenty; -import biomesoplenty.api.Blocks; import biomesoplenty.api.Items; public class BlockBOPGeneric extends Block diff --git a/src/minecraft/biomesoplenty/blocks/BlockBOPGlass.java b/src/minecraft/biomesoplenty/blocks/BlockBOPGlass.java index 0b07f8da1..3bdcf706a 100644 --- a/src/minecraft/biomesoplenty/blocks/BlockBOPGlass.java +++ b/src/minecraft/biomesoplenty/blocks/BlockBOPGlass.java @@ -3,13 +3,8 @@ package biomesoplenty.blocks; import java.util.List; import java.util.Random; -import cpw.mods.fml.client.FMLClientHandler; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - import net.minecraft.block.Block; import net.minecraft.block.material.Material; -import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.entity.Entity; @@ -27,6 +22,9 @@ import biomesoplenty.BiomesOPlenty; import biomesoplenty.api.Blocks; import biomesoplenty.api.Items; import biomesoplenty.tileentity.TileEntityAltar; +import cpw.mods.fml.client.FMLClientHandler; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; public class BlockBOPGlass extends Block { @@ -234,12 +232,14 @@ public class BlockBOPGlass extends Block return meta; } - public int quantityDropped(Random par1Random) + @Override + public int quantityDropped(Random par1Random) { return 0; } - @SideOnly(Side.CLIENT) + @Override + @SideOnly(Side.CLIENT) public int getRenderBlockPass() { return 1; @@ -251,12 +251,14 @@ public class BlockBOPGlass extends Block return super.shouldSideBeRendered(par1IBlockAccess, par2, par3, par4, 1 - par5); } - public boolean isOpaqueCube() + @Override + public boolean isOpaqueCube() { return false; } - protected boolean canSilkHarvest() + @Override + protected boolean canSilkHarvest() { return true; } diff --git a/src/minecraft/biomesoplenty/blocks/BlockBOPGrass.java b/src/minecraft/biomesoplenty/blocks/BlockBOPGrass.java index dcbfe35dc..a98560f47 100644 --- a/src/minecraft/biomesoplenty/blocks/BlockBOPGrass.java +++ b/src/minecraft/biomesoplenty/blocks/BlockBOPGrass.java @@ -77,12 +77,14 @@ public class BlockBOPGrass extends Block @Override public boolean isFireSource(World world, int x, int y, int z, int metadata, ForgeDirection side) { + int blockId = world.getBlockId(x, y, z); + if (metadata == 0) { - if (blockID == Block.netherrack.blockID && side == UP) + if (blockId == Block.netherrack.blockID && side == UP) return true; - if (blockID == blockID && side == UP) + if (blockId == this.blockID && side == UP) return true; if ((world.provider instanceof WorldProviderEnd) && blockID == Block.bedrock.blockID && side == UP) diff --git a/src/minecraft/biomesoplenty/blocks/BlockBOPPlant.java b/src/minecraft/biomesoplenty/blocks/BlockBOPPlant.java index d71f66fb4..309d88178 100644 --- a/src/minecraft/biomesoplenty/blocks/BlockBOPPlant.java +++ b/src/minecraft/biomesoplenty/blocks/BlockBOPPlant.java @@ -19,7 +19,7 @@ import net.minecraft.world.World; import net.minecraftforge.common.IShearable; import biomesoplenty.BiomesOPlenty; import biomesoplenty.api.Blocks; -import biomesoplenty.blocks.renderers.PlantsRenderer; +import biomesoplenty.blocks.renderers.RenderUtils; public class BlockBOPPlant extends BlockFlower implements IShearable { @@ -64,7 +64,7 @@ public class BlockBOPPlant extends BlockFlower implements IShearable @Override public int getRenderType () { - return PlantsRenderer.render; + return RenderUtils.plantsModel; } @Override diff --git a/src/minecraft/biomesoplenty/blocks/BlockBones.java b/src/minecraft/biomesoplenty/blocks/BlockBones.java index b036d1c7f..2c567c038 100644 --- a/src/minecraft/biomesoplenty/blocks/BlockBones.java +++ b/src/minecraft/biomesoplenty/blocks/BlockBones.java @@ -12,7 +12,7 @@ import net.minecraft.util.Icon; import net.minecraft.world.IBlockAccess; import net.minecraft.world.World; import biomesoplenty.BiomesOPlenty; -import biomesoplenty.blocks.renderers.SmallBlockRenderer; +import biomesoplenty.blocks.renderers.RenderUtils; public class BlockBones extends Block { //Meta 3 & 4 used by alternate small bone rotations, 5 & 6 are used by alternate medium bone rotations @@ -214,7 +214,7 @@ public class BlockBones extends Block { @Override public int getRenderType() { - return SmallBlockRenderer.bonesModel; + return RenderUtils.bonesModel; } @Override diff --git a/src/minecraft/biomesoplenty/blocks/BlockPuddle.java b/src/minecraft/biomesoplenty/blocks/BlockPuddle.java index 5762c6bb1..bb53e1541 100644 --- a/src/minecraft/biomesoplenty/blocks/BlockPuddle.java +++ b/src/minecraft/biomesoplenty/blocks/BlockPuddle.java @@ -10,7 +10,7 @@ import net.minecraft.util.Icon; import net.minecraft.world.World; import biomesoplenty.BiomesOPlenty; import biomesoplenty.ClientProxy; -import biomesoplenty.blocks.renderers.PuddleRender; +import biomesoplenty.blocks.renderers.RenderUtils; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; @@ -30,21 +30,31 @@ public class BlockPuddle extends Block this.setCreativeTab(BiomesOPlenty.tabBiomesOPlenty); } + @Override public AxisAlignedBB getCollisionBoundingBoxFromPool(World par1World, int par2, int par3, int par4) { return AxisAlignedBB.getAABBPool().getAABB((double)(par2 + 0), (double)(par3 + 0), (double)(par4 + 0), (double)(par2 + 1), (double)(par3 + 0.8135F), (double)(par4 + 1)); } + + @Override + public boolean isBlockNormalCube(World world, int x, int y, int z) + { + return false; + } + @Override public boolean isOpaqueCube() { return false; } + @Override public boolean renderAsNormalBlock() { return false; } + @Override public void updateTick(World world, int x, int y, int z, Random par5Random) { if (!world.isRaining() && world.rand.nextInt(750) == 0) @@ -69,28 +79,32 @@ public class BlockPuddle extends Block @Override public int getRenderType() { - return PuddleRender.puddleID; + return RenderUtils.puddleModel; } - @SideOnly(Side.CLIENT) + @Override + @SideOnly(Side.CLIENT) public Icon getIcon(int par1, int par2) { return Block.dirt.getBlockTextureFromSide(par1); } - public int idDropped(int par1, Random par2Random, int par3) + @Override + public int idDropped(int par1, Random par2Random, int par3) { return Block.dirt.idDropped(0, par2Random, par3); } - @SideOnly(Side.CLIENT) + @Override + @SideOnly(Side.CLIENT) public int idPicked(World par1World, int par2, int par3, int par4) { return Block.dirt.blockID; } - @SideOnly(Side.CLIENT) + @Override + @SideOnly(Side.CLIENT) public void registerIcons(IconRegister par1IconRegister) { } diff --git a/src/minecraft/biomesoplenty/blocks/renderers/AltarRenderer.java b/src/minecraft/biomesoplenty/blocks/renderers/AltarRenderer.java index b6ff3ecdd..29d33c580 100644 --- a/src/minecraft/biomesoplenty/blocks/renderers/AltarRenderer.java +++ b/src/minecraft/biomesoplenty/blocks/renderers/AltarRenderer.java @@ -1,20 +1,14 @@ package biomesoplenty.blocks.renderers; import net.minecraft.block.Block; -import net.minecraft.client.Minecraft; -import net.minecraft.client.renderer.EntityRenderer; import net.minecraft.client.renderer.RenderBlocks; import net.minecraft.client.renderer.Tessellator; import net.minecraft.util.Icon; import net.minecraft.world.IBlockAccess; -import net.minecraftforge.client.MinecraftForgeClient; import net.minecraftforge.common.ForgeDirection; -import biomesoplenty.BiomesOPlenty; -import biomesoplenty.api.Blocks; import biomesoplenty.blocks.BlockAltar; import biomesoplenty.tileentity.TileEntityAltar; import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; -import cpw.mods.fml.client.registry.RenderingRegistry; public class AltarRenderer implements ISimpleBlockRenderingHandler { @@ -29,36 +23,36 @@ public class AltarRenderer implements ISimpleBlockRenderingHandler { renderer.renderStandardBlock(block, x, y, z); - this.renderAltarSlotFaces(renderer, block, BlockAltar.altarFrame, world, x, y, z); + renderAltarSlotFaces(renderer, block, BlockAltar.altarFrame, world, x, y, z); if (tileentityaltar.getPresent(10)) { - this.renderAltarSlotFaces(renderer, block, BlockAltar.frameRuby, world, x, y, z); + renderAltarSlotFaces(renderer, block, BlockAltar.frameRuby, world, x, y, z); } if (tileentityaltar.getPresent(11)) { - this.renderAltarSlotFaces(renderer, block, BlockAltar.framePeridot, world, x, y, z); + renderAltarSlotFaces(renderer, block, BlockAltar.framePeridot, world, x, y, z); } if (tileentityaltar.getPresent(12)) { - this.renderAltarSlotFaces(renderer, block, BlockAltar.frameTopaz, world, x, y, z); + renderAltarSlotFaces(renderer, block, BlockAltar.frameTopaz, world, x, y, z); } if (tileentityaltar.getPresent(13)) { - this.renderAltarSlotFaces(renderer, block, BlockAltar.frameTanzanite, world, x, y, z); + renderAltarSlotFaces(renderer, block, BlockAltar.frameTanzanite, world, x, y, z); } if (tileentityaltar.getPresent(14)) { - this.renderAltarSlotFaces(renderer, block, BlockAltar.frameApatite, world, x, y, z); + renderAltarSlotFaces(renderer, block, BlockAltar.frameApatite, world, x, y, z); } if (tileentityaltar.getPresent(15)) { - this.renderAltarSlotFaces(renderer, block, BlockAltar.frameSapphire, world, x, y, z); + renderAltarSlotFaces(renderer, block, BlockAltar.frameSapphire, world, x, y, z); } } } diff --git a/src/minecraft/biomesoplenty/blocks/renderers/BlockSkinRenderHelper.java b/src/minecraft/biomesoplenty/blocks/renderers/BlockSkinRenderHelper.java index 72fcb1456..2229de878 100644 --- a/src/minecraft/biomesoplenty/blocks/renderers/BlockSkinRenderHelper.java +++ b/src/minecraft/biomesoplenty/blocks/renderers/BlockSkinRenderHelper.java @@ -1,7 +1,6 @@ package biomesoplenty.blocks.renderers; import net.minecraft.block.Block; -import net.minecraft.block.BlockGrass; import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.EntityRenderer; import net.minecraft.client.renderer.RenderBlocks; diff --git a/src/minecraft/biomesoplenty/blocks/renderers/FoliageRenderer.java b/src/minecraft/biomesoplenty/blocks/renderers/FoliageRenderer.java index 344dd128a..b6a18f5ac 100644 --- a/src/minecraft/biomesoplenty/blocks/renderers/FoliageRenderer.java +++ b/src/minecraft/biomesoplenty/blocks/renderers/FoliageRenderer.java @@ -7,11 +7,9 @@ import net.minecraft.client.renderer.Tessellator; import net.minecraft.world.IBlockAccess; import biomesoplenty.api.Blocks; import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; -import cpw.mods.fml.client.registry.RenderingRegistry; public class FoliageRenderer implements ISimpleBlockRenderingHandler { - public static int render = RenderingRegistry.getNextAvailableRenderId(); private final int GRASSTOP = 6; @Override @@ -25,7 +23,7 @@ public class FoliageRenderer implements ISimpleBlockRenderingHandler { int meta = world.getBlockMetadata(x, y, z); - if (modelId == render) + if (modelId == RenderUtils.foliageModel) { if (meta == 0) return renderer.renderBlockLilyPad(block, x, y, z); @@ -44,7 +42,7 @@ public class FoliageRenderer implements ISimpleBlockRenderingHandler @Override public int getRenderId() { - return render; + return RenderUtils.foliageModel; } private boolean renderCrossedSquares(Block par1Block, int par2, int par3, int par4, RenderBlocks renderer) diff --git a/src/minecraft/biomesoplenty/blocks/renderers/PlantsRenderer.java b/src/minecraft/biomesoplenty/blocks/renderers/PlantsRenderer.java index fd2aafb85..2d1036e5a 100644 --- a/src/minecraft/biomesoplenty/blocks/renderers/PlantsRenderer.java +++ b/src/minecraft/biomesoplenty/blocks/renderers/PlantsRenderer.java @@ -6,12 +6,9 @@ import net.minecraft.client.renderer.RenderBlocks; import net.minecraft.client.renderer.Tessellator; import net.minecraft.world.IBlockAccess; import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; -import cpw.mods.fml.client.registry.RenderingRegistry; public class PlantsRenderer implements ISimpleBlockRenderingHandler { - public static int render = RenderingRegistry.getNextAvailableRenderId(); - @Override public void renderInventoryBlock(Block block, int metadata, int modelID, RenderBlocks renderer) { @@ -21,7 +18,7 @@ public class PlantsRenderer implements ISimpleBlockRenderingHandler @Override public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) { - if (modelId == render) + if (modelId == RenderUtils.plantsModel) { int meta = world.getBlockMetadata(x, y, z); if (meta > 6) @@ -45,7 +42,7 @@ public class PlantsRenderer implements ISimpleBlockRenderingHandler @Override public int getRenderId() { - return render; + return RenderUtils.plantsModel; } private boolean renderBlockCrops(Block par1Block, int par2, int par3, int par4, RenderBlocks renderer) diff --git a/src/minecraft/biomesoplenty/blocks/renderers/PuddleRender.java b/src/minecraft/biomesoplenty/blocks/renderers/PuddleRender.java index c51d6af88..51a67e937 100644 --- a/src/minecraft/biomesoplenty/blocks/renderers/PuddleRender.java +++ b/src/minecraft/biomesoplenty/blocks/renderers/PuddleRender.java @@ -2,27 +2,16 @@ package biomesoplenty.blocks.renderers; import net.minecraft.block.Block; import net.minecraft.client.renderer.RenderBlocks; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.item.Item; import net.minecraft.world.IBlockAccess; -import net.minecraftforge.client.ForgeHooksClient; -import net.minecraftforge.liquids.LiquidStack; - -import org.lwjgl.opengl.GL11; - -import biomesoplenty.BiomesOPlenty; import biomesoplenty.ClientProxy; import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; -import cpw.mods.fml.client.registry.RenderingRegistry; public class PuddleRender implements ISimpleBlockRenderingHandler { - public static int puddleID = RenderingRegistry.getNextAvailableRenderId(); - @Override public void renderInventoryBlock (Block block, int metadata, int modelID, RenderBlocks renderer) { - if (modelID == puddleID) + if (modelID == RenderUtils.puddleModel) { RenderUtils.renderStandardInvBlock(renderer, block, metadata); } @@ -31,7 +20,7 @@ public class PuddleRender implements ISimpleBlockRenderingHandler @Override public boolean renderWorldBlock (IBlockAccess world, int x, int y, int z, Block block, int modelID, RenderBlocks renderer) { - if (modelID == puddleID) + if (modelID == RenderUtils.puddleModel) { if (ClientProxy.puddleRenderPass == 0) { @@ -39,7 +28,6 @@ public class PuddleRender implements ISimpleBlockRenderingHandler } else { - //Liquid renderer.setRenderBounds(0.0, 0.8135, 0.0, 1.0, 0.8880, 1.0); Block liquidBlock = Block.blocksList[Block.waterStill.blockID]; @@ -58,37 +46,6 @@ public class PuddleRender implements ISimpleBlockRenderingHandler @Override public int getRenderId() { - return puddleID; - } - - private void renderDoRe (RenderBlocks renderblocks, Block block, int meta) - { - Tessellator tessellator = Tessellator.instance; - GL11.glTranslatef(-0.5F, 0.5F, -0.5F); - tessellator.startDrawingQuads(); - tessellator.setNormal(0.0F, -1F, 0.0F); - renderblocks.renderFaceYNeg(block, 0.0D, 0.0D, 0.0D, block.getIcon(0, meta)); - tessellator.draw(); - tessellator.startDrawingQuads(); - tessellator.setNormal(0.0F, 1.0F, 0.0F); - renderblocks.renderFaceYPos(block, 0.0D, 0.0D, 0.0D, block.getIcon(1, meta)); - tessellator.draw(); - tessellator.startDrawingQuads(); - tessellator.setNormal(0.0F, 0.0F, -1F); - renderblocks.renderFaceZNeg(block, 0.0D, 0.0D, 0.0D, block.getIcon(2, meta)); - tessellator.draw(); - tessellator.startDrawingQuads(); - tessellator.setNormal(0.0F, 0.0F, 1.0F); - renderblocks.renderFaceZPos(block, 0.0D, 0.0D, 0.0D, block.getIcon(3, meta)); - tessellator.draw(); - tessellator.startDrawingQuads(); - tessellator.setNormal(-1F, 0.0F, 0.0F); - renderblocks.renderFaceXNeg(block, 0.0D, 0.0D, 0.0D, block.getIcon(4, meta)); - tessellator.draw(); - tessellator.startDrawingQuads(); - tessellator.setNormal(1.0F, 0.0F, 0.0F); - renderblocks.renderFaceXPos(block, 0.0D, 0.0D, 0.0D, block.getIcon(5, meta)); - tessellator.draw(); - GL11.glTranslatef(0.5F, 0.5F, 0.5F); + return RenderUtils.puddleModel; } } diff --git a/src/minecraft/biomesoplenty/blocks/renderers/RenderUtils.java b/src/minecraft/biomesoplenty/blocks/renderers/RenderUtils.java index a025b1873..bf89cb727 100644 --- a/src/minecraft/biomesoplenty/blocks/renderers/RenderUtils.java +++ b/src/minecraft/biomesoplenty/blocks/renderers/RenderUtils.java @@ -1,9 +1,5 @@ package biomesoplenty.blocks.renderers; -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.registry.RenderingRegistry; - import net.minecraft.block.Block; import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.EntityRenderer; @@ -13,9 +9,15 @@ import net.minecraft.util.Icon; import net.minecraft.world.IBlockAccess; import net.minecraftforge.common.ForgeDirection; +import org.lwjgl.opengl.GL11; + public class RenderUtils { public static int altarModel = -1; + public static int foliageModel = -1; + public static int plantsModel = -1; + public static int puddleModel = -1; + public static int bonesModel = -1; public static void renderStandardInvBlock(RenderBlocks renderblocks, Block block, int meta) { diff --git a/src/minecraft/biomesoplenty/blocks/renderers/SmallBlockRenderer.java b/src/minecraft/biomesoplenty/blocks/renderers/SmallBlockRenderer.java index 64901a22e..d6031165a 100644 --- a/src/minecraft/biomesoplenty/blocks/renderers/SmallBlockRenderer.java +++ b/src/minecraft/biomesoplenty/blocks/renderers/SmallBlockRenderer.java @@ -4,55 +4,45 @@ import net.minecraft.block.Block; import net.minecraft.client.renderer.RenderBlocks; import net.minecraft.client.renderer.Tessellator; import net.minecraft.world.IBlockAccess; -import biomesoplenty.BiomesOPlenty; import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; -import cpw.mods.fml.client.registry.RenderingRegistry; public class SmallBlockRenderer implements ISimpleBlockRenderingHandler { - public static int bonesModel = RenderingRegistry.getNextAvailableRenderId(); - @Override public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) { - if (modelId == bonesModel) + if (modelId == RenderUtils.bonesModel) { int meta = world.getBlockMetadata(x, y, z); //0.062 Approx (Per pixel) if (meta == 0) { - //renderer.setRenderBounds(0.25F, 0.0F, 0.25F, 0.75F, 1.0F, 0.75F); renderer.setRenderBounds(0.374F, 0.0F, 0.374F, 0.626F, 1.0F, 0.626F); renderer.renderStandardBlock(block, x, y, z); } else if (meta == 1) { - //renderer.setRenderBounds(0.125F, 0.0F, 0.125F, 0.875F, 1.0F, 0.875F); renderer.setRenderBounds(0.187F, 0.0F, 0.187F, 0.813F, 1.0F, 0.813F); renderer.renderStandardBlock(block, x, y, z); } else if (meta == 3) { - //renderer.setRenderBounds(0.25F, 0.25F, 0.0F, 0.75F, 0.75F, 1.0F); renderer.setRenderBounds(0.374F, 0.374F, 0.0F, 0.626F, 0.626F, 1.0F); renderer.renderStandardBlock(block, x, y, z); } else if (meta == 4) { - //renderer.setRenderBounds(0.0F, 0.25F, 0.25F, 1.0F, 0.75F, 0.75F); renderer.setRenderBounds(0.0F, 0.374F, 0.374F, 1.0F, 0.626F, 0.626F); renderer.renderStandardBlock(block, x, y, z); } else if (meta == 5) { - //renderer.setRenderBounds(0.125F, 0.125F, 0.0F, 0.875F, 0.875F, 1.0F); renderer.setRenderBounds(0.187F, 0.187F, 0.0F, 0.813F, 0.813F, 1.0F); renderer.renderStandardBlock(block, x, y, z); } else if (meta == 6) { - //renderer.setRenderBounds(0.0F, 0.125F, 0.125F, 1.0F, 0.875F, 0.875F); renderer.setRenderBounds(0.0F, 0.187F, 0.187F, 1.0F, 0.813F, 0.813F); renderer.renderStandardBlock(block, x, y, z); } @@ -68,7 +58,7 @@ public class SmallBlockRenderer implements ISimpleBlockRenderingHandler @Override public void renderInventoryBlock(Block block, int metadata, int modelID, RenderBlocks renderer) { - if (modelID == bonesModel) + if (modelID == RenderUtils.bonesModel) { Tessellator tessellator = Tessellator.instance; @@ -119,6 +109,6 @@ public class SmallBlockRenderer implements ISimpleBlockRenderingHandler @Override public int getRenderId() { - return bonesModel; + return RenderUtils.bonesModel; } } diff --git a/src/minecraft/biomesoplenty/configuration/BOPConfiguration.java b/src/minecraft/biomesoplenty/configuration/BOPConfiguration.java index 06d9d1f94..73a0706e6 100644 --- a/src/minecraft/biomesoplenty/configuration/BOPConfiguration.java +++ b/src/minecraft/biomesoplenty/configuration/BOPConfiguration.java @@ -3,15 +3,10 @@ package biomesoplenty.configuration; import java.io.File; import java.util.logging.Level; -import biomesoplenty.BiomesOPlenty; -import biomesoplenty.integration.TConstructIntegration; - -import net.minecraft.item.Item; import net.minecraftforge.common.Configuration; import net.minecraftforge.common.Property; import cpw.mods.fml.common.FMLCommonHandler; import cpw.mods.fml.common.FMLLog; -import cpw.mods.fml.common.Loader; public class BOPConfiguration { diff --git a/src/minecraft/biomesoplenty/configuration/BOPItems.java b/src/minecraft/biomesoplenty/configuration/BOPItems.java index c243c0130..ac0d16a76 100644 --- a/src/minecraft/biomesoplenty/configuration/BOPItems.java +++ b/src/minecraft/biomesoplenty/configuration/BOPItems.java @@ -3,11 +3,9 @@ package biomesoplenty.configuration; import java.util.Map; import java.util.logging.Level; -import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.EnumArmorMaterial; import net.minecraft.item.EnumToolMaterial; import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; import net.minecraftforge.common.EnumHelper; import net.minecraftforge.common.MinecraftForge; import biomesoplenty.BiomesOPlenty; @@ -38,7 +36,6 @@ import com.google.common.base.Optional; import cpw.mods.fml.common.FMLLog; import cpw.mods.fml.common.registry.GameData; -import cpw.mods.fml.common.registry.LanguageRegistry; import cpw.mods.fml.relauncher.ReflectionHelper; public class BOPItems { diff --git a/src/minecraft/biomesoplenty/configuration/BOPLiquids.java b/src/minecraft/biomesoplenty/configuration/BOPLiquids.java index 064ecaa31..a2f4c9898 100644 --- a/src/minecraft/biomesoplenty/configuration/BOPLiquids.java +++ b/src/minecraft/biomesoplenty/configuration/BOPLiquids.java @@ -19,7 +19,6 @@ import biomesoplenty.liquids.SpringWaterFluid; import com.google.common.base.Optional; import cpw.mods.fml.common.registry.GameRegistry; -import cpw.mods.fml.common.registry.LanguageRegistry; public class BOPLiquids { diff --git a/src/minecraft/biomesoplenty/configuration/BOPVanillaCompat.java b/src/minecraft/biomesoplenty/configuration/BOPVanillaCompat.java index 632ac7043..27d309ad7 100644 --- a/src/minecraft/biomesoplenty/configuration/BOPVanillaCompat.java +++ b/src/minecraft/biomesoplenty/configuration/BOPVanillaCompat.java @@ -8,7 +8,6 @@ import biomesoplenty.api.Blocks; import biomesoplenty.api.Items; import biomesoplenty.items.projectiles.DispenserBehaviorDart; import biomesoplenty.items.projectiles.DispenserBehaviorMudball; -import biomesoplenty.configuration.BOPConfiguration; public class BOPVanillaCompat { diff --git a/src/minecraft/biomesoplenty/handlers/BreakSpeedHandler.java b/src/minecraft/biomesoplenty/handlers/BreakSpeedHandler.java index 400491c05..548e412ec 100644 --- a/src/minecraft/biomesoplenty/handlers/BreakSpeedHandler.java +++ b/src/minecraft/biomesoplenty/handlers/BreakSpeedHandler.java @@ -1,15 +1,9 @@ package biomesoplenty.handlers; -import biomesoplenty.api.Blocks; import net.minecraft.block.Block; -import net.minecraft.block.material.Material; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayerMP; -import net.minecraft.item.EnumToolMaterial; import net.minecraft.item.Item; -import net.minecraft.item.ItemAxe; -import net.minecraft.item.ItemPickaxe; -import net.minecraft.item.ItemSpade; import net.minecraft.item.ItemStack; import net.minecraft.util.EnumMovingObjectType; import net.minecraft.util.MathHelper; @@ -17,8 +11,8 @@ import net.minecraft.util.MovingObjectPosition; import net.minecraft.util.Vec3; import net.minecraft.world.World; import net.minecraftforge.event.ForgeSubscribe; -import net.minecraftforge.event.Event.Result; import net.minecraftforge.event.entity.player.PlayerEvent; +import biomesoplenty.api.Blocks; public class BreakSpeedHandler { @@ -33,7 +27,7 @@ public class BreakSpeedHandler item = Item.itemsList[event.entityPlayer.getCurrentEquippedItem().itemID]; } - MovingObjectPosition movingobjectposition = this.getMovingObjectPositionFromPlayer(event.entityPlayer.worldObj, event.entityPlayer, true); + MovingObjectPosition movingobjectposition = getMovingObjectPositionFromPlayer(event.entityPlayer.worldObj, event.entityPlayer, true); if (movingobjectposition != null) { diff --git a/src/minecraft/biomesoplenty/handlers/MovementHandler.java b/src/minecraft/biomesoplenty/handlers/MovementHandler.java index 209011ec5..e6925afbc 100644 --- a/src/minecraft/biomesoplenty/handlers/MovementHandler.java +++ b/src/minecraft/biomesoplenty/handlers/MovementHandler.java @@ -1,13 +1,11 @@ package biomesoplenty.handlers; -import biomesoplenty.api.Blocks; -import net.minecraft.block.Block; -import net.minecraft.block.BlockFlower; import net.minecraft.entity.EntityLiving; import net.minecraft.util.MathHelper; import net.minecraft.world.World; import net.minecraftforge.event.ForgeSubscribe; import net.minecraftforge.event.entity.living.LivingEvent.LivingUpdateEvent; +import biomesoplenty.api.Blocks; public class MovementHandler { diff --git a/src/minecraft/biomesoplenty/handlers/SoundHandler.java b/src/minecraft/biomesoplenty/handlers/SoundHandler.java index 88001fa57..df3121ee1 100644 --- a/src/minecraft/biomesoplenty/handlers/SoundHandler.java +++ b/src/minecraft/biomesoplenty/handlers/SoundHandler.java @@ -1,18 +1,10 @@ package biomesoplenty.handlers; -import java.io.File; -import java.io.FileOutputStream; -import java.io.InputStream; -import java.io.OutputStream; import java.util.logging.Level; -import net.minecraft.client.Minecraft; import net.minecraftforge.client.event.sound.PlayStreamingEvent; import net.minecraftforge.client.event.sound.SoundLoadEvent; import net.minecraftforge.event.ForgeSubscribe; - -import biomesoplenty.BiomesOPlenty; -import biomesoplenty.ClientProxy; import cpw.mods.fml.client.FMLClientHandler; import cpw.mods.fml.common.FMLCommonHandler; import cpw.mods.fml.relauncher.Side; diff --git a/src/minecraft/biomesoplenty/handlers/TickHandlerClient.java b/src/minecraft/biomesoplenty/handlers/TickHandlerClient.java index 511c64531..412e1d41e 100644 --- a/src/minecraft/biomesoplenty/handlers/TickHandlerClient.java +++ b/src/minecraft/biomesoplenty/handlers/TickHandlerClient.java @@ -2,9 +2,8 @@ package biomesoplenty.handlers; import java.util.EnumSet; -import biomesoplenty.helpers.Version; - import net.minecraft.entity.player.EntityPlayer; +import biomesoplenty.helpers.Version; import cpw.mods.fml.common.ITickHandler; import cpw.mods.fml.common.Loader; import cpw.mods.fml.common.TickType; diff --git a/src/minecraft/biomesoplenty/helpers/Version.java b/src/minecraft/biomesoplenty/helpers/Version.java index 5e43f283a..b88dd0a3f 100644 --- a/src/minecraft/biomesoplenty/helpers/Version.java +++ b/src/minecraft/biomesoplenty/helpers/Version.java @@ -8,10 +8,8 @@ import java.util.ArrayList; import java.util.logging.Level; import net.minecraft.world.World; -import net.minecraft.world.WorldSettings; import net.minecraft.world.WorldType; import net.minecraftforge.common.Property; -import biomesoplenty.BiomesOPlenty; import biomesoplenty.configuration.BOPConfiguration; import biomesoplenty.world.WorldTypeBOP; import cpw.mods.fml.common.FMLCommonHandler; diff --git a/src/minecraft/biomesoplenty/integration/TConstructIntegration.java b/src/minecraft/biomesoplenty/integration/TConstructIntegration.java index 992aa56ec..4ed904db6 100644 --- a/src/minecraft/biomesoplenty/integration/TConstructIntegration.java +++ b/src/minecraft/biomesoplenty/integration/TConstructIntegration.java @@ -1,10 +1,7 @@ package biomesoplenty.integration; import mods.tinker.tconstruct.library.TConstructRegistry; -import net.minecraft.item.ItemStack; -import biomesoplenty.api.Blocks; import biomesoplenty.integration.tinkersconstruct.TCItems; -import cpw.mods.fml.common.event.FMLInterModComms; public class TConstructIntegration { diff --git a/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPCraftingItem.java b/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPCraftingItem.java index 49fe8b411..2679d2452 100644 --- a/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPCraftingItem.java +++ b/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPCraftingItem.java @@ -29,6 +29,7 @@ public class BOPCraftingItem extends Item this.folder = folder; } + @Override @SideOnly(Side.CLIENT) public Icon getIconFromDamage(int meta) { @@ -47,13 +48,15 @@ public class BOPCraftingItem extends Item } } + @Override public String getUnlocalizedName(ItemStack stack) { int arr = MathHelper.clamp_int(stack.getItemDamage(), 0, unlocalizedNames.length); return getUnlocalizedName() + "." +unlocalizedNames[arr]; } - public void getSubItems (int id, CreativeTabs tab, List list) + @Override + public void getSubItems(int id, CreativeTabs tab, List list) { for (int i = 0; i < unlocalizedNames.length; i++) list.add(new ItemStack(id, 1, i)); diff --git a/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPToolPart.java b/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPToolPart.java index a1f88f575..ad82265ec 100644 --- a/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPToolPart.java +++ b/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPToolPart.java @@ -1,17 +1,7 @@ package biomesoplenty.integration.tinkersconstruct; -import java.util.List; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -import mods.tinker.tconstruct.library.TConstructRegistry; import mods.tinker.tconstruct.library.util.IToolPart; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; -import net.minecraft.util.MathHelper; public class BOPToolPart extends BOPCraftingItem implements IToolPart { diff --git a/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPToolShard.java b/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPToolShard.java index d80ef200e..5a1490c1e 100644 --- a/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPToolShard.java +++ b/src/minecraft/biomesoplenty/integration/tinkersconstruct/BOPToolShard.java @@ -2,13 +2,12 @@ package biomesoplenty.integration.tinkersconstruct; import java.util.List; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.ItemStack; import net.minecraft.util.Icon; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; public class BOPToolShard extends BOPToolPart { @@ -19,7 +18,7 @@ public class BOPToolShard extends BOPToolPart this.setMaxDamage(0); } - private static String[] buildTextureNames (String textureType) + private static String[] buildTextureNames(String textureType) { String[] names = new String[toolMaterialNames.length]; for (int i = 0; i < toolMaterialNames.length; i++) @@ -27,6 +26,7 @@ public class BOPToolShard extends BOPToolPart return names; } + @Override @SideOnly(Side.CLIENT) public void registerIcons(IconRegister iconRegister) { @@ -38,7 +38,8 @@ public class BOPToolShard extends BOPToolPart } } - public void getSubItems (int id, CreativeTabs tab, List list) + @Override + public void getSubItems(int id, CreativeTabs tab, List list) { for (int i = 0; i < toolMaterialNames.length; i++) list.add(new ItemStack(id, 1, i)); diff --git a/src/minecraft/biomesoplenty/integration/tinkersconstruct/TCItems.java b/src/minecraft/biomesoplenty/integration/tinkersconstruct/TCItems.java index 6998fae33..dd32c25dc 100644 --- a/src/minecraft/biomesoplenty/integration/tinkersconstruct/TCItems.java +++ b/src/minecraft/biomesoplenty/integration/tinkersconstruct/TCItems.java @@ -1,16 +1,12 @@ package biomesoplenty.integration.tinkersconstruct; -import java.util.Iterator; - import mods.tinker.tconstruct.library.TConstructRegistry; import mods.tinker.tconstruct.library.client.TConstructClientRegistry; import mods.tinker.tconstruct.library.crafting.PatternBuilder; import mods.tinker.tconstruct.library.crafting.ToolBuilder; import mods.tinker.tconstruct.library.tools.ToolCore; -import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.potion.PotionEffect; import biomesoplenty.api.Items; import biomesoplenty.configuration.BOPConfiguration; @@ -100,23 +96,22 @@ public class TCItems TConstructClientRegistry.addMaterialRenderMapping(150 + partIter, "BiomesOPlenty", partTypes[partIter], true); } - ToolBuilder tb = ToolBuilder.instance; - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("pickaxe"), pickaxeHead, toolRod, binding); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("broadsword"), swordBlade, toolRod, wideGuard); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("hatchet"), hatchetHead, toolRod); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("shovel"), shovelHead, toolRod); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("longsword"), swordBlade, toolRod, handGuard); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("rapier"), swordBlade, toolRod, crossbar); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("frypan"), frypanHead, toolRod); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("battlesign"), signHead, toolRod); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("mattock"), hatchetHead, toolRod, shovelHead); - //tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("dagger"), knifeBlade, crossbar); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("chisel"), chiselHead, toolRod); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("scythe"), scytheBlade, toughRod, toughBinding, toughRod); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("lumberaxe"), broadAxeHead, toughRod, heavyPlate, toughBinding); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("cleaver"), largeSwordBlade, toughRod, heavyPlate, toughRod); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("excavator"), excavatorHead, toughRod, heavyPlate, toughBinding); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("hammer"), hammerHead, toughRod, heavyPlate, heavyPlate); - tb.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("battleaxe"), broadAxeHead, toughRod, broadAxeHead, toughBinding); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("pickaxe"), pickaxeHead, toolRod, binding); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("broadsword"), swordBlade, toolRod, wideGuard); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("hatchet"), hatchetHead, toolRod); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("shovel"), shovelHead, toolRod); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("longsword"), swordBlade, toolRod, handGuard); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("rapier"), swordBlade, toolRod, crossbar); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("frypan"), frypanHead, toolRod); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("battlesign"), signHead, toolRod); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("mattock"), hatchetHead, toolRod, shovelHead); + //ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("dagger"), knifeBlade, crossbar); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("chisel"), chiselHead, toolRod); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("scythe"), scytheBlade, toughRod, toughBinding, toughRod); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("lumberaxe"), broadAxeHead, toughRod, heavyPlate, toughBinding); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("cleaver"), largeSwordBlade, toughRod, heavyPlate, toughRod); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("excavator"), excavatorHead, toughRod, heavyPlate, toughBinding); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("hammer"), hammerHead, toughRod, heavyPlate, heavyPlate); + ToolBuilder.addNormalToolRecipe((ToolCore)TConstructRegistry.getItem("battleaxe"), broadAxeHead, toughRod, broadAxeHead, toughBinding); } } diff --git a/src/minecraft/biomesoplenty/items/ItemBOP.java b/src/minecraft/biomesoplenty/items/ItemBOP.java index e531c2ede..50fccfb08 100644 --- a/src/minecraft/biomesoplenty/items/ItemBOP.java +++ b/src/minecraft/biomesoplenty/items/ItemBOP.java @@ -2,13 +2,8 @@ package biomesoplenty.items; import java.util.List; -import net.minecraft.block.BlockCloth; -import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.entity.EntityLiving; -import net.minecraft.entity.passive.EntitySheep; -import net.minecraft.entity.passive.EntityWolf; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.util.Icon; diff --git a/src/minecraft/biomesoplenty/items/ItemBOPScythe.java b/src/minecraft/biomesoplenty/items/ItemBOPScythe.java index 806d20ef6..964cd0f86 100644 --- a/src/minecraft/biomesoplenty/items/ItemBOPScythe.java +++ b/src/minecraft/biomesoplenty/items/ItemBOPScythe.java @@ -7,11 +7,8 @@ import net.minecraft.entity.Entity; import net.minecraft.entity.EntityLiving; import net.minecraft.item.EnumToolMaterial; import net.minecraft.item.Item; -import net.minecraft.item.ItemPickaxe; import net.minecraft.item.ItemStack; -import net.minecraft.item.ItemTool; import net.minecraft.world.World; -import net.minecraftforge.oredict.OreDictionary; import biomesoplenty.BiomesOPlenty; import biomesoplenty.api.Blocks; import biomesoplenty.api.Items; @@ -36,7 +33,8 @@ public class ItemBOPScythe extends Item setCreativeTab(BiomesOPlenty.tabBiomesOPlenty); } - public boolean onBlockDestroyed(ItemStack itemstack, World world, int meta, int x, int y, int z, EntityLiving entity) + @Override + public boolean onBlockDestroyed(ItemStack itemstack, World world, int meta, int x, int y, int z, EntityLiving entity) { Block block = Block.blocksList[world.getBlockId(x, y, z)]; int radius = 1; diff --git a/src/minecraft/biomesoplenty/items/ItemSoulManipulator.java b/src/minecraft/biomesoplenty/items/ItemSoulManipulator.java index ea9d0db53..03741bf1f 100644 --- a/src/minecraft/biomesoplenty/items/ItemSoulManipulator.java +++ b/src/minecraft/biomesoplenty/items/ItemSoulManipulator.java @@ -4,20 +4,10 @@ import java.util.List; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.entity.Entity; -import net.minecraft.entity.monster.EntityEnderman; -import net.minecraft.entity.passive.EntityVillager; -import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.util.DamageSource; -import net.minecraft.util.EnumMovingObjectType; import net.minecraft.util.Icon; -import net.minecraft.util.MathHelper; -import net.minecraft.util.MovingObjectPosition; -import net.minecraft.world.World; import biomesoplenty.BiomesOPlenty; -import cpw.mods.fml.client.FMLClientHandler; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; diff --git a/src/minecraft/biomesoplenty/liquids/BlockFluidLiquidPoison.java b/src/minecraft/biomesoplenty/liquids/BlockFluidLiquidPoison.java index 824e24f94..b364b8356 100644 --- a/src/minecraft/biomesoplenty/liquids/BlockFluidLiquidPoison.java +++ b/src/minecraft/biomesoplenty/liquids/BlockFluidLiquidPoison.java @@ -12,7 +12,6 @@ import net.minecraft.world.IBlockAccess; import net.minecraft.world.World; import net.minecraftforge.fluids.BlockFluidClassic; import net.minecraftforge.fluids.Fluid; -import net.minecraftforge.fluids.FluidStack; import net.minecraftforge.liquids.ILiquid; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; @@ -22,8 +21,6 @@ public class BlockFluidLiquidPoison extends BlockFluidClassic implements ILiquid public static Icon liquidPoisonStillIcon; public static Icon liquidPoisonFlowingIcon; - private static FluidStack stack; - public BlockFluidLiquidPoison(int id, Fluid fluid, Material material) { super(id, fluid, material); diff --git a/src/minecraft/biomesoplenty/liquids/LiquidPoisonFluid.java b/src/minecraft/biomesoplenty/liquids/LiquidPoisonFluid.java index 6249ec5bf..c7e855b09 100644 --- a/src/minecraft/biomesoplenty/liquids/LiquidPoisonFluid.java +++ b/src/minecraft/biomesoplenty/liquids/LiquidPoisonFluid.java @@ -1,9 +1,9 @@ package biomesoplenty.liquids; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; import net.minecraft.util.Icon; import net.minecraftforge.fluids.Fluid; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; public class LiquidPoisonFluid extends Fluid { @@ -14,15 +14,17 @@ public class LiquidPoisonFluid extends Fluid this.setViscosity(2500); } - @SideOnly(Side.CLIENT) - public Icon getStillIcon() { - + @Override + @SideOnly(Side.CLIENT) + public Icon getStillIcon() + { return BlockFluidLiquidPoison.liquidPoisonStillIcon; } - @SideOnly(Side.CLIENT) - public Icon getFlowingIcon() { - + @Override + @SideOnly(Side.CLIENT) + public Icon getFlowingIcon() + { return BlockFluidLiquidPoison.liquidPoisonFlowingIcon; } } diff --git a/src/minecraft/biomesoplenty/liquids/SpringWaterFluid.java b/src/minecraft/biomesoplenty/liquids/SpringWaterFluid.java index 385b2524a..b1230c2f4 100644 --- a/src/minecraft/biomesoplenty/liquids/SpringWaterFluid.java +++ b/src/minecraft/biomesoplenty/liquids/SpringWaterFluid.java @@ -1,9 +1,9 @@ package biomesoplenty.liquids; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; import net.minecraft.util.Icon; import net.minecraftforge.fluids.Fluid; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; public class SpringWaterFluid extends Fluid { @@ -12,15 +12,17 @@ public class SpringWaterFluid extends Fluid super(fluidName); } - @SideOnly(Side.CLIENT) - public Icon getStillIcon() { - + @Override + @SideOnly(Side.CLIENT) + public Icon getStillIcon() + { return BlockFluidSpringWater.springWaterStillIcon; } - @SideOnly(Side.CLIENT) - public Icon getFlowingIcon() { - + @Override + @SideOnly(Side.CLIENT) + public Icon getFlowingIcon() + { return BlockFluidSpringWater.springWaterFlowingIcon; } } diff --git a/src/minecraft/biomesoplenty/tileentity/TileEntityAltar.java b/src/minecraft/biomesoplenty/tileentity/TileEntityAltar.java index 477ca3993..93da6a5af 100644 --- a/src/minecraft/biomesoplenty/tileentity/TileEntityAltar.java +++ b/src/minecraft/biomesoplenty/tileentity/TileEntityAltar.java @@ -1,14 +1,10 @@ package biomesoplenty.tileentity; -import java.lang.reflect.Field; - -import net.minecraft.client.Minecraft; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.network.INetworkManager; import net.minecraft.network.packet.Packet; import net.minecraft.network.packet.Packet132TileEntityData; import net.minecraft.tileentity.TileEntity; -import net.minecraft.world.World; public class TileEntityAltar extends TileEntity { @@ -143,9 +139,7 @@ public class TileEntityAltar extends TileEntity { return true; } - else - { - return false; - } + + return false; } } diff --git a/src/minecraft/biomesoplenty/world/ChunkProviderBOPNaturaHell.java b/src/minecraft/biomesoplenty/world/ChunkProviderBOPNaturaHell.java index 6e040c525..1c6151f84 100644 --- a/src/minecraft/biomesoplenty/world/ChunkProviderBOPNaturaHell.java +++ b/src/minecraft/biomesoplenty/world/ChunkProviderBOPNaturaHell.java @@ -7,14 +7,9 @@ import static net.minecraftforge.event.terraingen.PopulateChunkEvent.Populate.Ev import static net.minecraftforge.event.terraingen.PopulateChunkEvent.Populate.EventType.GLOWSTONE; import static net.minecraftforge.event.terraingen.PopulateChunkEvent.Populate.EventType.NETHER_LAVA; -import java.lang.reflect.Constructor; -import java.lang.reflect.InvocationTargetException; -import java.lang.reflect.Method; import java.util.List; import java.util.Random; -import biomesoplenty.worldgen.WorldGenFlowersMeta; - import net.minecraft.block.Block; import net.minecraft.block.BlockSand; import net.minecraft.entity.EnumCreatureType; @@ -33,7 +28,6 @@ import net.minecraft.world.gen.feature.WorldGenGlowStone1; import net.minecraft.world.gen.feature.WorldGenGlowStone2; import net.minecraft.world.gen.feature.WorldGenHellLava; import net.minecraft.world.gen.feature.WorldGenMinable; -import net.minecraft.world.gen.feature.WorldGenerator; import net.minecraft.world.gen.structure.MapGenNetherBridge; import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.event.Event.Result; @@ -41,6 +35,7 @@ import net.minecraftforge.event.terraingen.ChunkProviderEvent; import net.minecraftforge.event.terraingen.DecorateBiomeEvent; import net.minecraftforge.event.terraingen.PopulateChunkEvent; import net.minecraftforge.event.terraingen.TerrainGen; +import biomesoplenty.worldgen.WorldGenFlowersMeta; public class ChunkProviderBOPNaturaHell implements IChunkProvider { @@ -174,7 +169,7 @@ public class ChunkProviderBOPNaturaHell implements IChunkProvider if (d15 > 56.0D) { - l2 = this.taintedSoil.blockID; + l2 = taintedSoil.blockID; } par3ArrayOfByte[j2] = (byte)l2; @@ -222,7 +217,7 @@ public class ChunkProviderBOPNaturaHell implements IChunkProvider int i1 = (int)(netherrackExclusivityNoise[k + l * 16] / 3.0D + 3.0D + hellRNG.nextDouble() * 0.25D); int j1 = -1; byte b1 = biomegenbase.topBlock; - byte b2 = (byte) this.taintedSoil.blockID; + byte b2 = (byte) taintedSoil.blockID; for (int k1 = 127; k1 >= 0; --k1) { @@ -243,12 +238,12 @@ public class ChunkProviderBOPNaturaHell implements IChunkProvider if (i1 <= 0) { b1 = 0; - b2 = (byte)Block.netherrack.blockID; + b2 = (byte) Block.netherrack.blockID; } else if (k1 >= b0 - 4 && k1 <= b0 + 1) { - b1 = (byte)Block.netherrack.blockID; - b2 = (byte) this.taintedSoil.blockID; + b1 = (byte) Block.netherrack.blockID; + b2 = (byte) taintedSoil.blockID; if (flag1) { @@ -267,7 +262,7 @@ public class ChunkProviderBOPNaturaHell implements IChunkProvider if (flag) { - b2 = (byte) this.heatSand.blockID; + b2 = (byte) heatSand.blockID; } } @@ -598,21 +593,21 @@ public class ChunkProviderBOPNaturaHell implements IChunkProvider int l2 = k + hellRNG.nextInt(16) + 8; int k4 = hellRNG.nextInt(128); int j6 = l + hellRNG.nextInt(16) + 8; - (new WorldGenFlowersMeta(this.glowshroom.blockID, 0)).generate(worldObj, hellRNG, l2, k4, j6); + (new WorldGenFlowersMeta(glowshroom.blockID, 0)).generate(worldObj, hellRNG, l2, k4, j6); } if (doGen && hellRNG.nextInt(8) == 0) { int i3 = k + hellRNG.nextInt(16) + 8; int l4 = hellRNG.nextInt(128); int k6 = l + hellRNG.nextInt(16) + 8; - (new WorldGenFlowersMeta(this.glowshroom.blockID, 1)).generate(worldObj, hellRNG, i3, l4, k6); + (new WorldGenFlowersMeta(glowshroom.blockID, 1)).generate(worldObj, hellRNG, i3, l4, k6); } if (doGen && hellRNG.nextInt(9) == 0) { int i3 = k + hellRNG.nextInt(16) + 8; int l4 = hellRNG.nextInt(128); int k6 = l + hellRNG.nextInt(16) + 8; - (new WorldGenFlowersMeta(this.glowshroom.blockID, 2)).generate(worldObj, hellRNG, i3, l4, k6); + (new WorldGenFlowersMeta(glowshroom.blockID, 2)).generate(worldObj, hellRNG, i3, l4, k6); } MinecraftForge.EVENT_BUS.post(new DecorateBiomeEvent.Post(worldObj, hellRNG, k, l)); diff --git a/src/minecraft/biomesoplenty/world/WorldChunkManagerBOP.java b/src/minecraft/biomesoplenty/world/WorldChunkManagerBOP.java index 516568994..616e5c29d 100644 --- a/src/minecraft/biomesoplenty/world/WorldChunkManagerBOP.java +++ b/src/minecraft/biomesoplenty/world/WorldChunkManagerBOP.java @@ -352,7 +352,8 @@ public class WorldChunkManagerBOP extends WorldChunkManager } } - public GenLayer[] getModdedBiomeGenerators(WorldType worldType, long seed, GenLayer[] original) + @Override + public GenLayer[] getModdedBiomeGenerators(WorldType worldType, long seed, GenLayer[] original) { WorldTypeEvent.InitBiomeGens event = new WorldTypeEvent.InitBiomeGens(worldType, seed, original); MinecraftForge.TERRAIN_GEN_BUS.post(event); diff --git a/src/minecraft/biomesoplenty/world/WorldProviderBOPhell.java b/src/minecraft/biomesoplenty/world/WorldProviderBOPhell.java index f63bef720..8ded65c7d 100644 --- a/src/minecraft/biomesoplenty/world/WorldProviderBOPhell.java +++ b/src/minecraft/biomesoplenty/world/WorldProviderBOPhell.java @@ -1,14 +1,14 @@ package biomesoplenty.world; -import cpw.mods.fml.common.Loader; import net.minecraft.world.WorldProviderHell; import net.minecraft.world.chunk.IChunkProvider; import biomesoplenty.api.Biomes; -import biomesoplenty.integration.BCIntegration; +import cpw.mods.fml.common.Loader; public class WorldProviderBOPhell extends WorldProviderHell { - public void registerWorldChunkManager() + @Override + public void registerWorldChunkManager() { if (Biomes.netherGarden.isPresent() || Biomes.netherDesert.isPresent() || Biomes.netherLava.isPresent() || Biomes.netherBone.isPresent()) { diff --git a/src/minecraft/biomesoplenty/world/WorldProviderPromised.java b/src/minecraft/biomesoplenty/world/WorldProviderPromised.java index c07e1faa6..134b53b7b 100644 --- a/src/minecraft/biomesoplenty/world/WorldProviderPromised.java +++ b/src/minecraft/biomesoplenty/world/WorldProviderPromised.java @@ -4,7 +4,6 @@ import net.minecraft.util.ChunkCoordinates; import net.minecraft.util.MathHelper; import net.minecraft.util.Vec3; import net.minecraft.world.WorldProvider; -import net.minecraft.world.WorldProviderHell; import net.minecraft.world.chunk.IChunkProvider; import biomesoplenty.api.Biomes; import biomesoplenty.api.Blocks; diff --git a/src/minecraft/biomesoplenty/world/layer/BiomeLayerBiomes.java b/src/minecraft/biomesoplenty/world/layer/BiomeLayerBiomes.java index 1f5dc8275..0af243c69 100644 --- a/src/minecraft/biomesoplenty/world/layer/BiomeLayerBiomes.java +++ b/src/minecraft/biomesoplenty/world/layer/BiomeLayerBiomes.java @@ -90,7 +90,8 @@ public class BiomeLayerBiomes extends BiomeLayer } } - public int[] getInts(int par1, int par2, int par3, int par4) + @Override + public int[] getInts(int par1, int par2, int par3, int par4) { int[] var5 = this.parent.getInts(par1, par2, par3, par4); int[] var6 = IntCache.getIntCache(par3 * par4); diff --git a/src/minecraft/biomesoplenty/world/layer/BiomeLayerCreate.java b/src/minecraft/biomesoplenty/world/layer/BiomeLayerCreate.java index 90bfc2a37..164e32350 100644 --- a/src/minecraft/biomesoplenty/world/layer/BiomeLayerCreate.java +++ b/src/minecraft/biomesoplenty/world/layer/BiomeLayerCreate.java @@ -1,7 +1,6 @@ package biomesoplenty.world.layer; import net.minecraft.world.gen.layer.IntCache; -import biomesoplenty.api.Biomes; public class BiomeLayerCreate extends BiomeLayer { diff --git a/src/minecraft/biomesoplenty/world/layer/BiomeLayerShore.java b/src/minecraft/biomesoplenty/world/layer/BiomeLayerShore.java index 7f7d6b66f..f942e987d 100644 --- a/src/minecraft/biomesoplenty/world/layer/BiomeLayerShore.java +++ b/src/minecraft/biomesoplenty/world/layer/BiomeLayerShore.java @@ -2,10 +2,9 @@ package biomesoplenty.world.layer; import java.util.ArrayList; -import biomesoplenty.api.Biomes; - import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.gen.layer.IntCache; +import biomesoplenty.api.Biomes; public class BiomeLayerShore extends BiomeLayer { diff --git a/src/minecraft/biomesoplenty/worldgen/WorldGenAcacia.java b/src/minecraft/biomesoplenty/worldgen/WorldGenAcacia.java index 2c95a326b..105e4c64e 100644 --- a/src/minecraft/biomesoplenty/worldgen/WorldGenAcacia.java +++ b/src/minecraft/biomesoplenty/worldgen/WorldGenAcacia.java @@ -16,11 +16,9 @@ public class WorldGenAcacia extends WorldGenerator private final boolean vinesGrow; /** The metadata value of the wood to use in tree generation. */ - @SuppressWarnings("unused") private final int metaWood; /** The metadata value of the leaves to use in tree generation. */ - @SuppressWarnings("unused") private final int metaLeaves; public WorldGenAcacia(boolean par1) diff --git a/src/minecraft/biomesoplenty/worldgen/WorldGenFlowersMeta.java b/src/minecraft/biomesoplenty/worldgen/WorldGenFlowersMeta.java index 7daf918ae..aa8ca447a 100644 --- a/src/minecraft/biomesoplenty/worldgen/WorldGenFlowersMeta.java +++ b/src/minecraft/biomesoplenty/worldgen/WorldGenFlowersMeta.java @@ -25,7 +25,8 @@ public class WorldGenFlowersMeta extends WorldGenerator this.chances = count; } - public boolean generate(World world, Random random, int x, int y, int z) + @Override + public boolean generate(World world, Random random, int x, int y, int z) { for (int iter = 0; iter < chances; ++iter) { diff --git a/src/minecraft/biomesoplenty/worldgen/WorldGenIceSheet.java b/src/minecraft/biomesoplenty/worldgen/WorldGenIceSheet.java index 799c21bcb..fdf4ef287 100644 --- a/src/minecraft/biomesoplenty/worldgen/WorldGenIceSheet.java +++ b/src/minecraft/biomesoplenty/worldgen/WorldGenIceSheet.java @@ -8,6 +8,7 @@ import net.minecraft.world.gen.feature.WorldGenerator; public class WorldGenIceSheet extends WorldGenerator { + @SuppressWarnings("unused") @Override public boolean generate(World par1World, Random par2Random, int par3, int par4, int par5) { diff --git a/src/minecraft/biomesoplenty/worldgen/WorldGenMarsh.java b/src/minecraft/biomesoplenty/worldgen/WorldGenMarsh.java index 90f389816..65e90cff0 100644 --- a/src/minecraft/biomesoplenty/worldgen/WorldGenMarsh.java +++ b/src/minecraft/biomesoplenty/worldgen/WorldGenMarsh.java @@ -9,6 +9,7 @@ import biomesoplenty.api.Blocks; public class WorldGenMarsh extends WorldGenerator { + @SuppressWarnings("unused") @Override public boolean generate(World par1World, Random par2Random, int par3, int par4, int par5) { diff --git a/src/minecraft/biomesoplenty/worldgen/WorldGenMoor.java b/src/minecraft/biomesoplenty/worldgen/WorldGenMoor.java index 3bf192cc2..001f31d41 100644 --- a/src/minecraft/biomesoplenty/worldgen/WorldGenMoor.java +++ b/src/minecraft/biomesoplenty/worldgen/WorldGenMoor.java @@ -8,6 +8,7 @@ import net.minecraft.world.gen.feature.WorldGenerator; public class WorldGenMoor extends WorldGenerator { + @SuppressWarnings("unused") @Override public boolean generate(World par1World, Random par2Random, int par3, int par4, int par5) { diff --git a/src/minecraft/mods/tinker/tconstruct/library/TConstructRegistry.java b/src/minecraft/mods/tinker/tconstruct/library/TConstructRegistry.java index 9d1ba5ff2..8fccbdb5b 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/TConstructRegistry.java +++ b/src/minecraft/mods/tinker/tconstruct/library/TConstructRegistry.java @@ -6,12 +6,14 @@ import java.util.Arrays; import java.util.HashMap; import java.util.List; -import mods.tinker.tconstruct.library.crafting.*; -import mods.tinker.tconstruct.library.tools.*; -import mods.tinker.tconstruct.library.util.*; +import mods.tinker.tconstruct.library.crafting.Detailing; +import mods.tinker.tconstruct.library.crafting.LiquidCasting; +import mods.tinker.tconstruct.library.crafting.ToolBuilder; +import mods.tinker.tconstruct.library.tools.ToolCore; +import mods.tinker.tconstruct.library.tools.ToolMaterial; +import mods.tinker.tconstruct.library.util.TabTools; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraftforge.common.ForgeHooks; /** A registry to store any relevant API work * @@ -179,7 +181,8 @@ public class TConstructRegistry * @param output The ToolCore to craft * @param parts Pieces to make the tool with */ - public static void addToolRecipe(ToolCore output, Item... parts) + @SuppressWarnings("static-access") + public static void addToolRecipe(ToolCore output, Item... parts) { ToolBuilder tb = ToolBuilder.instance; if (parts.length < 1 || parts.length > 4 || parts.length == 3) diff --git a/src/minecraft/mods/tinker/tconstruct/library/blocks/InventoryBlock.java b/src/minecraft/mods/tinker/tconstruct/library/blocks/InventoryBlock.java index ab67cfc11..0319ef6a9 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/blocks/InventoryBlock.java +++ b/src/minecraft/mods/tinker/tconstruct/library/blocks/InventoryBlock.java @@ -27,9 +27,11 @@ public abstract class InventoryBlock extends BlockContainer } /* Logic backend */ - public TileEntity createNewTileEntity (World var1) + @Override + public TileEntity createNewTileEntity (World var1) { return null; } - public abstract TileEntity createTileEntity(World world, int metadata); + @Override + public abstract TileEntity createTileEntity(World world, int metadata); public abstract Integer getGui(World world, int x, int y, int z, EntityPlayer entityplayer); public abstract Object getModInstance(); @@ -133,7 +135,8 @@ public abstract class InventoryBlock extends BlockContainer return false; } - public int damageDropped (int meta) + @Override + public int damageDropped (int meta) { return meta; } diff --git a/src/minecraft/mods/tinker/tconstruct/library/blocks/InventoryLogic.java b/src/minecraft/mods/tinker/tconstruct/library/blocks/InventoryLogic.java index 3f345680c..efef1e834 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/blocks/InventoryLogic.java +++ b/src/minecraft/mods/tinker/tconstruct/library/blocks/InventoryLogic.java @@ -145,18 +145,23 @@ public abstract class InventoryLogic extends TileEntity } /* Default implementations of hardly used methods */ + @Override public ItemStack getStackInSlotOnClosing (int slot) { return null; } + @Override public void openChest () {} + @Override public void closeChest () {} protected abstract String getDefaultName(); + @Override public String getInvName() { return this.isInvNameLocalized() ? this.invName : getDefaultName(); } - public boolean isInvNameLocalized() + @Override + public boolean isInvNameLocalized() { return this.invName != null && this.invName.length() > 0; } diff --git a/src/minecraft/mods/tinker/tconstruct/library/crafting/Detailing.java b/src/minecraft/mods/tinker/tconstruct/library/crafting/Detailing.java index aa3b426a0..821086a48 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/crafting/Detailing.java +++ b/src/minecraft/mods/tinker/tconstruct/library/crafting/Detailing.java @@ -7,7 +7,6 @@ import mods.tinker.tconstruct.library.tools.ToolCore; import net.minecraft.block.Block; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.item.crafting.ShapelessRecipes; import net.minecraft.nbt.NBTTagCompound; import cpw.mods.fml.common.registry.GameRegistry; diff --git a/src/minecraft/mods/tinker/tconstruct/library/crafting/LiquidCasting.java b/src/minecraft/mods/tinker/tconstruct/library/crafting/LiquidCasting.java index 57441dd77..c59a57f87 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/crafting/LiquidCasting.java +++ b/src/minecraft/mods/tinker/tconstruct/library/crafting/LiquidCasting.java @@ -1,9 +1,6 @@ package mods.tinker.tconstruct.library.crafting; import java.util.ArrayList; -import java.util.Arrays; -import java.util.HashMap; -import java.util.List; import net.minecraft.item.ItemStack; import net.minecraftforge.liquids.LiquidStack; diff --git a/src/minecraft/mods/tinker/tconstruct/library/tools/DualHarvestTool.java b/src/minecraft/mods/tinker/tconstruct/library/tools/DualHarvestTool.java index ae708fbae..7419dd0ba 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/tools/DualHarvestTool.java +++ b/src/minecraft/mods/tinker/tconstruct/library/tools/DualHarvestTool.java @@ -107,6 +107,7 @@ public abstract class DualHarvestTool extends HarvestTool return super.getStrVsBlock(stack, block, meta); } + @Override public boolean canHarvestBlock (Block block) { if (block.blockMaterial.isToolNotRequired()) diff --git a/src/minecraft/mods/tinker/tconstruct/library/tools/HarvestTool.java b/src/minecraft/mods/tinker/tconstruct/library/tools/HarvestTool.java index 9379d6e82..2cefca49e 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/tools/HarvestTool.java +++ b/src/minecraft/mods/tinker/tconstruct/library/tools/HarvestTool.java @@ -102,6 +102,7 @@ public abstract class HarvestTool extends ToolCore return super.getStrVsBlock(stack, block, meta); } + @Override public boolean canHarvestBlock (Block block) { if (block.blockMaterial.isToolNotRequired()) diff --git a/src/minecraft/mods/tinker/tconstruct/library/tools/ToolCore.java b/src/minecraft/mods/tinker/tconstruct/library/tools/ToolCore.java index 53c6c5df6..77898d4b5 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/tools/ToolCore.java +++ b/src/minecraft/mods/tinker/tconstruct/library/tools/ToolCore.java @@ -488,7 +488,8 @@ public abstract class ToolCore extends Item static String[] toolMaterialNames = { "Wooden ", "Stone ", "Iron ", "Flint ", "Cactus ", "Bone ", "Obsidian ", "Netherrack ", "Slime ", "Paper ", "Cobalt ", "Ardite ", "Manyullyn ", "Copper ", "Bronze ", "Alumite ", "Steel ", "Slime " }; - public void getSubItems (int id, CreativeTabs tab, List list) + @Override + public void getSubItems (int id, CreativeTabs tab, List list) { for (int i = 0; i < 18; i++) { @@ -526,7 +527,8 @@ public abstract class ToolCore extends Item /* Updating */ - public void onUpdate (ItemStack stack, World world, Entity entity, int par4, boolean par5) + @Override + public void onUpdate (ItemStack stack, World world, Entity entity, int par4, boolean par5) { for (ActiveToolMod mod : TConstructRegistry.activeModifiers) { @@ -592,7 +594,8 @@ public abstract class ToolCore extends Item return 1f; } - public int getDamageVsEntity (Entity par1Entity) + @Override + public int getDamageVsEntity (Entity par1Entity) { return this.damageVsEntity; } @@ -614,7 +617,8 @@ public abstract class ToolCore extends Item } //Right-click - public boolean onItemUse (ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float clickX, float clickY, float clickZ) + @Override + public boolean onItemUse (ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float clickX, float clickY, float clickZ) { /*if (world.isRemote) return true;*/ @@ -687,7 +691,8 @@ public abstract class ToolCore extends Item } //Vanilla overrides - public boolean isItemTool (ItemStack par1ItemStack) + @Override + public boolean isItemTool (ItemStack par1ItemStack) { return false; } @@ -698,23 +703,27 @@ public abstract class ToolCore extends Item return false; } - public boolean isRepairable () + @Override + public boolean isRepairable () { return false; } - public int getItemEnchantability () + @Override + public int getItemEnchantability () { return 0; } - public boolean isFull3D () + @Override + public boolean isFull3D () { return true; } /* Proper stack damage */ - public int getItemDamageFromStack (ItemStack stack) + @Override + public int getItemDamageFromStack (ItemStack stack) { NBTTagCompound tags = stack.getTagCompound(); if (tags == null) @@ -728,7 +737,8 @@ public abstract class ToolCore extends Item return tags.getCompoundTag("InfiTool").getInteger("Damage"); } - public int getItemDamageFromStackForDisplay (ItemStack stack) + @Override + public int getItemDamageFromStackForDisplay (ItemStack stack) { NBTTagCompound tags = stack.getTagCompound(); if (tags == null) @@ -742,7 +752,8 @@ public abstract class ToolCore extends Item return tags.getCompoundTag("InfiTool").getInteger("Damage"); } - public int getItemMaxDamageFromStack (ItemStack stack) + @Override + public int getItemMaxDamageFromStack (ItemStack stack) { NBTTagCompound tags = stack.getTagCompound(); if (tags == null) diff --git a/src/minecraft/mods/tinker/tconstruct/library/tools/ToolMod.java b/src/minecraft/mods/tinker/tconstruct/library/tools/ToolMod.java index 0053dacf2..172ff2f1b 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/tools/ToolMod.java +++ b/src/minecraft/mods/tinker/tconstruct/library/tools/ToolMod.java @@ -1,7 +1,6 @@ package mods.tinker.tconstruct.library.tools; import java.util.ArrayList; -import java.util.Arrays; import java.util.Iterator; import java.util.List; import java.util.Random; diff --git a/src/minecraft/mods/tinker/tconstruct/library/tools/Weapon.java b/src/minecraft/mods/tinker/tconstruct/library/tools/Weapon.java index 613b8d92d..3b1cbc1c0 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/tools/Weapon.java +++ b/src/minecraft/mods/tinker/tconstruct/library/tools/Weapon.java @@ -44,7 +44,8 @@ public abstract class Weapon extends ToolCore /** * returns the action that specifies what animation to play when the items is being used */ - public EnumAction getItemUseAction(ItemStack par1ItemStack) + @Override + public EnumAction getItemUseAction(ItemStack par1ItemStack) { return EnumAction.block; } @@ -52,7 +53,8 @@ public abstract class Weapon extends ToolCore /** * How long it takes to use or consume an item */ - public int getMaxItemUseDuration(ItemStack par1ItemStack) + @Override + public int getMaxItemUseDuration(ItemStack par1ItemStack) { return 72000; } @@ -60,13 +62,15 @@ public abstract class Weapon extends ToolCore /** * Called whenever this item is equipped and the right mouse button is pressed. Args: itemStack, world, entityPlayer */ - public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player) + @Override + public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player) { player.setItemInUse(stack, this.getMaxItemUseDuration(stack)); return stack; } - public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float clickX, float clickY, float clickZ) + @Override + public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float clickX, float clickY, float clickZ) { return false; } @@ -74,7 +78,8 @@ public abstract class Weapon extends ToolCore /** * Returns if the item (tool) can harvest results from the block type. */ - public boolean canHarvestBlock(Block block) + @Override + public boolean canHarvestBlock(Block block) { for (int i = 0; i < web.length; i++) { diff --git a/src/minecraft/mods/tinker/tconstruct/library/util/CoordTuple.java b/src/minecraft/mods/tinker/tconstruct/library/util/CoordTuple.java index 5996e6b01..25fc867f6 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/util/CoordTuple.java +++ b/src/minecraft/mods/tinker/tconstruct/library/util/CoordTuple.java @@ -47,7 +47,8 @@ public class CoordTuple return result; } - public String toString () + @Override + public String toString () { return "X: " + x + ", Y: " + y + ", Z: " + z; } diff --git a/src/minecraft/mods/tinker/tconstruct/library/util/TabTools.java b/src/minecraft/mods/tinker/tconstruct/library/util/TabTools.java index e78f2b810..c711551b9 100755 --- a/src/minecraft/mods/tinker/tconstruct/library/util/TabTools.java +++ b/src/minecraft/mods/tinker/tconstruct/library/util/TabTools.java @@ -17,6 +17,7 @@ public class TabTools extends CreativeTabs display = stack; } + @Override public ItemStack getIconItemStack() { return display;