Renamed constants
This commit is contained in:
@@ -53,7 +53,7 @@ public class AEConfig extends Configuration implements IConfigurableObject, ICon
|
||||
|
||||
public static AEConfig instance;
|
||||
|
||||
public static final double TunnelPowerLoss = 0.05;
|
||||
public static final double TUNNEL_POWER_LOSS = 0.05;
|
||||
|
||||
public String latestVersion = VERSION;
|
||||
public long latestTimeStamp = 0;
|
||||
|
||||
@@ -42,7 +42,7 @@ import appeng.util.Platform;
|
||||
public class Api implements IAppEngApi
|
||||
{
|
||||
|
||||
public static final Api instance = new Api();
|
||||
public static final Api INSTANCE = new Api();
|
||||
|
||||
private Api() {
|
||||
|
||||
|
||||
@@ -178,7 +178,7 @@ public class AppEng
|
||||
public void serverStopping( FMLServerStoppingEvent event )
|
||||
{
|
||||
WorldSettings.getInstance().shutdown();
|
||||
TickHandler.instance.shutdown();
|
||||
TickHandler.INSTANCE.shutdown();
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
|
||||
@@ -252,12 +252,12 @@ public final class Registration
|
||||
RecipeSorter.register( "AE2-Shaped", ShapedRecipe.class, Category.SHAPED, "" );
|
||||
RecipeSorter.register( "AE2-Shapeless", ShapelessRecipe.class, Category.SHAPELESS, "" );
|
||||
|
||||
MinecraftForge.EVENT_BUS.register( OreDictionaryHandler.instance );
|
||||
MinecraftForge.EVENT_BUS.register( OreDictionaryHandler.INSTANCE );
|
||||
|
||||
Items items = Api.instance.items();
|
||||
Materials materials = Api.instance.materials();
|
||||
Parts parts = Api.instance.parts();
|
||||
Blocks blocks = Api.instance.blocks();
|
||||
Items items = Api.INSTANCE.items();
|
||||
Materials materials = Api.INSTANCE.materials();
|
||||
Parts parts = Api.INSTANCE.parts();
|
||||
Blocks blocks = Api.INSTANCE.blocks();
|
||||
|
||||
AEItemDefinition materialItem = this.addFeature( ItemMultiMaterial.class );
|
||||
|
||||
@@ -573,8 +573,8 @@ public final class Registration
|
||||
if ( AppEng.instance.isIntegrationEnabled( IntegrationType.RF ) )
|
||||
ph.registerNewLayer( "appeng.parts.layers.LayerIEnergyHandler", "cofh.api.energy.IEnergyReceiver" );
|
||||
|
||||
FMLCommonHandler.instance().bus().register( TickHandler.instance );
|
||||
MinecraftForge.EVENT_BUS.register( TickHandler.instance );
|
||||
FMLCommonHandler.instance().bus().register( TickHandler.INSTANCE );
|
||||
MinecraftForge.EVENT_BUS.register( TickHandler.INSTANCE );
|
||||
|
||||
PartPlacement pp = new PartPlacement();
|
||||
MinecraftForge.EVENT_BUS.register( pp );
|
||||
@@ -627,7 +627,7 @@ public final class Registration
|
||||
PlayerMessages.values();
|
||||
GuiText.values();
|
||||
|
||||
Api.instance.partHelper.initFMPSupport();
|
||||
Api.INSTANCE.partHelper.initFMPSupport();
|
||||
( ( BlockCableBus ) blocks.blockMultiPart.block() ).setupTile();
|
||||
|
||||
// Interface
|
||||
@@ -777,6 +777,6 @@ public final class Registration
|
||||
/**
|
||||
* initial recipe bake, if ore dictionary changes after this it re-bakes.
|
||||
*/
|
||||
OreDictionaryHandler.instance.bakeRecipes();
|
||||
OreDictionaryHandler.INSTANCE.bakeRecipes();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -336,7 +336,7 @@ public class WorldSettings extends Configuration
|
||||
}
|
||||
else
|
||||
{
|
||||
for ( PlayerColor pc : TickHandler.instance.getPlayerColors().values() )
|
||||
for ( PlayerColor pc : TickHandler.INSTANCE.getPlayerColors().values() )
|
||||
NetworkHandler.instance.sendToAll( pc.getPacket() );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -331,7 +331,7 @@ public class ApiPart implements IPartHelper
|
||||
public void setItemBusRenderer(IPartItem i)
|
||||
{
|
||||
if ( Platform.isClient() && i instanceof Item )
|
||||
MinecraftForgeClient.registerItemRenderer( (Item) i, BusRenderer.instance );
|
||||
MinecraftForgeClient.registerItemRenderer( (Item) i, BusRenderer.INSTANCE );
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -71,7 +71,7 @@ public class GrinderRecipeManager implements IGrinderRegistry, IOreListener
|
||||
|
||||
this.addIngot( "Wheat", new ItemStack( Items.wheat ) );
|
||||
|
||||
OreDictionaryHandler.instance.observe( this );
|
||||
OreDictionaryHandler.INSTANCE.observe( this );
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -127,7 +127,7 @@ public class MatterCannonAmmoRegistry implements IOreListener, IMatterCannonAmmo
|
||||
}
|
||||
|
||||
public MatterCannonAmmoRegistry() {
|
||||
OreDictionaryHandler.instance.observe( this );
|
||||
OreDictionaryHandler.INSTANCE.observe( this );
|
||||
this.registerAmmo( new ItemStack( Items.gold_nugget ), 196.96655 );
|
||||
}
|
||||
|
||||
|
||||
@@ -124,7 +124,7 @@ public class RegistryContainer implements IRegistryContainer
|
||||
@Override
|
||||
public IWorldGen worldgen()
|
||||
{
|
||||
return WorldGenRegistry.instance;
|
||||
return WorldGenRegistry.INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -39,7 +39,7 @@ public class WorldGenRegistry implements IWorldGen
|
||||
|
||||
final TypeSet[] types;
|
||||
|
||||
static final public WorldGenRegistry instance = new WorldGenRegistry();
|
||||
static final public WorldGenRegistry INSTANCE = new WorldGenRegistry();
|
||||
|
||||
private WorldGenRegistry() {
|
||||
|
||||
|
||||
@@ -53,7 +53,7 @@ import appeng.core.sync.packets.PacketValueConfig;
|
||||
public class AppEngPacketHandlerBase
|
||||
{
|
||||
|
||||
public static final Map<Class, PacketTypes> reverseLookup = new HashMap<Class, AppEngPacketHandlerBase.PacketTypes>();
|
||||
public static final Map<Class, PacketTypes> REVERSE_LOOKUP = new HashMap<Class, AppEngPacketHandlerBase.PacketTypes>();
|
||||
|
||||
public enum PacketTypes
|
||||
{
|
||||
@@ -124,7 +124,7 @@ public class AppEngPacketHandlerBase
|
||||
}
|
||||
|
||||
this.con = x;
|
||||
AppEngPacketHandlerBase.reverseLookup.put( this.pc, this );
|
||||
AppEngPacketHandlerBase.REVERSE_LOOKUP.put( this.pc, this );
|
||||
|
||||
if ( this.con == null )
|
||||
throw new RuntimeException( "Invalid Packet Class, must be constructable on DataInputStream" );
|
||||
@@ -142,7 +142,7 @@ public class AppEngPacketHandlerBase
|
||||
|
||||
public static PacketTypes getID(Class<? extends AppEngPacket> c)
|
||||
{
|
||||
return AppEngPacketHandlerBase.reverseLookup.get( c );
|
||||
return AppEngPacketHandlerBase.REVERSE_LOOKUP.get( c );
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -49,7 +49,7 @@ public class PacketCompassResponse extends AppEngPacket
|
||||
@Override
|
||||
public void clientPacketData(INetworkInfo network, AppEngPacket packet, EntityPlayer player)
|
||||
{
|
||||
CompassManager.instance.postResult( this.attunement, this.cx << 4, this.cdy << 5, this.cz << 4, this.cr );
|
||||
CompassManager.INSTANCE.postResult( this.attunement, this.cx << 4, this.cdy << 5, this.cz << 4, this.cr );
|
||||
}
|
||||
|
||||
// api
|
||||
|
||||
@@ -48,7 +48,7 @@ public class PacketPaintedEntity extends AppEngPacket
|
||||
public void clientPacketData(INetworkInfo network, AppEngPacket packet, EntityPlayer player)
|
||||
{
|
||||
PlayerColor pc = new PlayerColor( this.entityId, this.myColor, this.ticks );
|
||||
TickHandler.instance.getPlayerColors().put( this.entityId, pc );
|
||||
TickHandler.INSTANCE.getPlayerColors().put( this.entityId, pc );
|
||||
}
|
||||
|
||||
// api
|
||||
|
||||
Reference in New Issue
Block a user