Made the April Fools joke a liiiiiiiiiiitle less invasive

This commit is contained in:
Matt Caughey 2014-04-01 10:31:54 -04:00
parent d6e50e9ad9
commit e5c3636f0b
15 changed files with 48 additions and 155 deletions

View File

@ -66,13 +66,6 @@ public class BlockBOPColorizedLeaves extends BlockLeavesBase implements IShearab
this.setCreativeTab(BiomesOPlenty.tabBiomesOPlenty);
}
public static boolean isTime()
{
Calendar calendar = Calendar.getInstance();
return (calendar.get(2) + 1 == 4 && calendar.get(5) == 1);
}
@Override
//TODO: registerIcons()
public void registerBlockIcons(IIconRegister iconRegister)
@ -82,16 +75,6 @@ public class BlockBOPColorizedLeaves extends BlockLeavesBase implements IShearab
if(Loader.isModLoaded("BetterGrassAndLeavesMod"))
{
for (int i = 0; i < leaves.length; ++i)
{
if (!BOPConfigurationMisc.behaveNormally)
{
if (isTime())
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:foolleaves_round");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:foolleaves_fast");
textures[2][i] = iconRegister.registerIcon("biomesoplenty:foolleaves_better");
}
else
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_round");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fast");
@ -99,37 +82,13 @@ public class BlockBOPColorizedLeaves extends BlockLeavesBase implements IShearab
}
}
else
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_round");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fast");
textures[2][i] = iconRegister.registerIcon("biomesoplenty:better_leaves_" + leaves[i]);
}
}
}
else
{
for (int i = 0; i < leaves.length; ++i)
{
if (!BOPConfigurationMisc.behaveNormally)
{
if (isTime())
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:foolleaves_fancy");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:foolleaves_fast");
}
else
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fancy");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fast");
}
}
else
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fancy");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fast");
}
}
}
}
public IIcon getIconBetterLeaves(int metadata, float randomIndex)

View File

@ -62,13 +62,6 @@ public class BlockBOPFoliage extends BlockTallGrass implements IShearable
this.setCreativeTab(BiomesOPlenty.tabBiomesOPlenty);
}
public static boolean isTime()
{
Calendar calendar = Calendar.getInstance();
return (calendar.get(2) + 1 == 4 && calendar.get(5) == 1);
}
@Override
//TODO: registerIcons()
public void registerBlockIcons(IIconRegister iconRegister)
@ -76,30 +69,9 @@ public class BlockBOPFoliage extends BlockTallGrass implements IShearable
textures = new IIcon[foliageTypes.length];
for (int i = 0; i < textures.length; ++i)
{
if (!BOPConfigurationMisc.behaveNormally)
{
if (isTime())
{
if (i != 1 && i != 2 && i != 10 && i != 11)
{
textures[i] = iconRegister.registerIcon("biomesoplenty:"+foliageTypes[i]);
}
else
{
textures[i] = iconRegister.registerIcon("biomesoplenty:foolgrass");
}
}
else
{
textures[i] = iconRegister.registerIcon("biomesoplenty:"+foliageTypes[i]);
}
}
else
{
textures[i] = iconRegister.registerIcon("biomesoplenty:"+foliageTypes[i]);
}
}
hedgeTrunk = iconRegister.registerIcon("biomesoplenty:" + "hedge_trunk");
shrubBranch = iconRegister.registerIcon("biomesoplenty:" + "shrub_branch");

View File

@ -83,13 +83,6 @@ public class BlockBOPLeaves extends BlockLeavesBase implements IShearable
this.setCreativeTab(BiomesOPlenty.tabBiomesOPlenty);
}
public static boolean isTime()
{
Calendar calendar = Calendar.getInstance();
return (calendar.get(2) + 1 == 4 && calendar.get(5) == 1);
}
@Override
//TODO: registerIcons()
public void registerBlockIcons(IIconRegister iconRegister)
@ -97,52 +90,18 @@ public class BlockBOPLeaves extends BlockLeavesBase implements IShearable
textures = new IIcon[3][leaves.length];
if(Loader.isModLoaded("BetterGrassAndLeavesMod"))
for (int i = 0; i < leaves.length; ++i)
{
if (!BOPConfigurationMisc.behaveNormally)
{
if (isTime())
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:foolleaves_round");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:foolleaves_fast");
textures[2][i] = iconRegister.registerIcon("biomesoplenty:foolleaves_better");
}
else
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_round");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fast");
textures[2][i] = iconRegister.registerIcon("biomesoplenty:better_leaves_" + leaves[i]);
}
}
else
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_round");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fast");
textures[2][i] = iconRegister.registerIcon("biomesoplenty:better_leaves_" + leaves[i]);
}
}
else
for (int i = 0; i < leaves.length; ++i)
{
if (!BOPConfigurationMisc.behaveNormally)
{
if (isTime())
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:foolleaves_fancy");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:foolleaves_fast");
}
else
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fancy");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fast");
}
}
else
{
textures[0][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fancy");
textures[1][i] = iconRegister.registerIcon("biomesoplenty:leaves_" + leaves[i] + "_fast");
}
}
}
public IIcon getIconBetterLeaves(int metadata, float randomIndex)
{

View File

@ -75,13 +75,6 @@ public class BlockBOPLog extends Block
this.setCreativeTab(BiomesOPlenty.tabBiomesOPlenty);
}
public static boolean isTime()
{
Calendar calendar = Calendar.getInstance();
return (calendar.get(2) + 1 == 4 && calendar.get(5) == 1);
}
@Override
//TODO: registerIcons()
public void registerBlockIcons(IIconRegister iconRegister)
@ -89,37 +82,14 @@ public class BlockBOPLog extends Block
textures = new IIcon[types.length];
logHearts = new IIcon[types.length];
if (!BOPConfigurationMisc.behaveNormally)
{
if (isTime())
{
}
}
for (int i = 0; i < types.length; ++i)
{
if (i != 11)
{
if (!BOPConfigurationMisc.behaveNormally)
{
if (isTime())
{
textures[i] = iconRegister.registerIcon("biomesoplenty:foollog_side");
logHearts[i] = iconRegister.registerIcon("biomesoplenty:foollog_heart");
}
else
{
textures[i] = iconRegister.registerIcon("biomesoplenty:log_"+types[i]+"_side");
logHearts[i] = iconRegister.registerIcon("biomesoplenty:log_"+types[i]+"_heart");
}
}
else
{
textures[i] = iconRegister.registerIcon("biomesoplenty:log_"+types[i]+"_side");
logHearts[i] = iconRegister.registerIcon("biomesoplenty:log_"+types[i]+"_heart");
}
}
}
textures[11] = iconRegister.registerIcon("biomesoplenty:bigflowerstem_side");
logHearts[11] = iconRegister.registerIcon("biomesoplenty:bigflowerstem_heart");

View File

@ -1,5 +1,6 @@
package biomesoplenty.common.blocks;
import java.util.Calendar;
import java.util.List;
import net.minecraft.block.Block;
@ -15,6 +16,7 @@ import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import biomesoplenty.BiomesOPlenty;
import biomesoplenty.api.BOPBlockHelper;
import biomesoplenty.common.configuration.BOPConfigurationMisc;
public class BlockBOPMushroom extends BlockBush
{
@ -44,15 +46,46 @@ public class BlockBOPMushroom extends BlockBush
this.setCreativeTab(BiomesOPlenty.tabBiomesOPlenty);
}
public static boolean isTime()
{
Calendar calendar = Calendar.getInstance();
return (calendar.get(2) + 1 == 4 && calendar.get(5) == 1);
}
@Override
//TODO: registerIcons()
public void registerBlockIcons(IIconRegister iconRegister)
{
textures = new IIcon[plants.length];
for (int i = 0; i < plants.length; ++i) {
for (int i = 0; i < plants.length; ++i)
{
if (!BOPConfigurationMisc.behaveNormally)
{
if (isTime())
{
if (i != 0 && i != 1 && i != 4)
{
textures[i] = iconRegister.registerIcon("biomesoplenty:" + plants[i]);
}
else
{
textures[0] = iconRegister.registerIcon("biomesoplenty:toadhard");
textures[1] = iconRegister.registerIcon("biomesoplenty:kappabello");
textures[4] = iconRegister.registerIcon("biomesoplenty:frankershroom");
}
}
else
{
textures[i] = iconRegister.registerIcon("biomesoplenty:" + plants[i]);
}
}
else
{
textures[i] = iconRegister.registerIcon("biomesoplenty:" + plants[i]);
}
}
}
@Override

Binary file not shown.

Before

Width:  |  Height:  |  Size: 641 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1021 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 742 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 823 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 686 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 931 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 833 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 721 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 716 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 794 B