Creative Energy Cube now won't be drained of or receive power.

This commit is contained in:
Aidan Brady 2014-07-31 19:19:03 -04:00
parent ed4aa7671c
commit da35b509fd
4 changed files with 10 additions and 2 deletions

View file

@ -46,7 +46,7 @@ public final class Tier
ADVANCED("Advanced", EnumColor.DARK_RED, 8000000, 3200), ADVANCED("Advanced", EnumColor.DARK_RED, 8000000, 3200),
ELITE("Elite", EnumColor.DARK_BLUE, 32000000, 12800), ELITE("Elite", EnumColor.DARK_BLUE, 32000000, 12800),
ULTIMATE("Ultimate", EnumColor.PURPLE, 128000000, 51200), ULTIMATE("Ultimate", EnumColor.PURPLE, 128000000, 51200),
CREATIVE("Creative", EnumColor.BLACK, Integer.MAX_VALUE, Integer.MAX_VALUE/2D); CREATIVE("Creative", EnumColor.BLACK, Integer.MAX_VALUE, Integer.MAX_VALUE);
public double MAX_ELECTRICITY; public double MAX_ELECTRICITY;
public double OUTPUT; public double OUTPUT;

View file

@ -247,8 +247,9 @@ public class TileEntityEnergyCube extends TileEntityElectricBlock implements IPe
{ {
if(tier == EnergyCubeTier.CREATIVE) if(tier == EnergyCubeTier.CREATIVE)
{ {
energy = Integer.MAX_VALUE / 2D; return;
} }
super.setEnergy(energy); super.setEnergy(energy);
int newRedstoneLevel = getRedstoneLevel(); int newRedstoneLevel = getRedstoneLevel();

View file

@ -1156,6 +1156,11 @@ public final class MekanismUtils
*/ */
public static String getEnergyDisplay(double energy) public static String getEnergyDisplay(double energy)
{ {
if(energy == Integer.MAX_VALUE)
{
return localize("gui.infinite");
}
switch(Mekanism.activeType) switch(Mekanism.activeType)
{ {
case J: case J:

View file

@ -162,6 +162,7 @@ tile.EnergyCube.Basic.name=Basic Energy Cube
tile.EnergyCube.Advanced.name=Advanced Energy Cube tile.EnergyCube.Advanced.name=Advanced Energy Cube
tile.EnergyCube.Elite.name=Elite Energy Cube tile.EnergyCube.Elite.name=Elite Energy Cube
tile.EnergyCube.Ultimate.name=Ultimate Energy Cube tile.EnergyCube.Ultimate.name=Ultimate Energy Cube
tile.EnergyCube.Creative.name=Creative Energy Cube
//Dust //Dust
item.ironDust.name=Iron Dust item.ironDust.name=Iron Dust
@ -357,6 +358,7 @@ gui.id=ID
gui.finished=Finished gui.finished=Finished
gui.well=All is well! gui.well=All is well!
gui.upgrade=Upgrade gui.upgrade=Upgrade
gui.infinite=Infinite
gui.upgrades=Upgrades gui.upgrades=Upgrades
gui.upgrades.supported=Supported gui.upgrades.supported=Supported