Code cleanup

This commit is contained in:
LemADEC 2016-05-15 01:11:36 -04:00
parent f4751f466c
commit 1e729938de
5 changed files with 6 additions and 6 deletions

View file

@ -21,7 +21,7 @@ public abstract class TileEntityAbstractBase extends TileEntity implements IBloc
public void updatedNeighbours() {
}
protected boolean isOnEarth() {
protected boolean isOnPlanet() {
return worldObj.provider.dimensionId == 0;
}

View file

@ -376,7 +376,7 @@ public abstract class TileEntityAbstractEnergy extends TileEntityAbstractInterfa
}
// WarpDrive overrides for Thermal Expansion FIXME: are we really supposed to do this?
// WarpDrive overrides for Thermal Expansion
@Optional.Method(modid = "CoFHCore")
private void outputEnergy(ForgeDirection from, IEnergyReceiver energyReceiver) {
if (energyReceiver == null || worldObj.getTileEntity(xCoord + from.offsetX, yCoord + from.offsetY, zCoord + from.offsetZ) == null) {

View file

@ -88,7 +88,7 @@ public class TileEntityMiningLaser extends TileEntityAbstractMiner {
return;
}
boolean isOnEarth = isOnEarth();
boolean isOnEarth = isOnPlanet();
if (currentState == STATE_WARMUP) {
delayTicksWarmup++;

View file

@ -541,7 +541,7 @@ public class TileEntityShipCore extends TileEntityAbstractEnergy {
}
updateShipMassAndVolume();
if (!isUnlimited && shipMass > WarpDriveConfig.SHIP_VOLUME_MAX_ON_PLANET_SURFACE && worldObj.provider.dimensionId == 0) {// FIXME: need to support any planets and landing movement
if (!isUnlimited && shipMass > WarpDriveConfig.SHIP_VOLUME_MAX_ON_PLANET_SURFACE && isOnPlanet()) {
reason.append("Ship is too big for a planet (max is " + WarpDriveConfig.SHIP_VOLUME_MAX_ON_PLANET_SURFACE + " blocks)");
return false;
}

View file

@ -84,7 +84,7 @@ public final class EntityCamera extends EntityLivingBase {
ClientCameraHandler.overlayLoggingMessage = "Mouse " + Mouse.isButtonDown(0) + " " + Mouse.isButtonDown(1) + " " + Mouse.isButtonDown(2) + " " + Mouse.isButtonDown(3) + "\nBackspace "
+ Keyboard.isKeyDown(Keyboard.KEY_BACKSLASH) + " Space " + Keyboard.isKeyDown(Keyboard.KEY_SPACE) + " Shift " + "";
// Perform zoom
if (Mouse.isButtonDown(0)) {// FIXME merge: main is using right click with Mouse.isButtonDown(1), branch is using left click
if (Mouse.isButtonDown(0)) {
zoomWaitTicks++;
if (zoomWaitTicks >= 2) {
zoomWaitTicks = 0;
@ -108,7 +108,7 @@ public final class EntityCamera extends EntityLivingBase {
}
}
if (Keyboard.isKeyDown(Keyboard.KEY_SPACE)) {// FIXME merge: main is using left click with Mouse.isButtonDown(0), branch is using space bar
if (Keyboard.isKeyDown(Keyboard.KEY_SPACE)) {
fireWaitTicks++;
if (fireWaitTicks >= 2) {
fireWaitTicks = 0;