Fix missing default perdition calculator.

This commit is contained in:
SirSengir 2013-08-07 16:05:04 +02:00
parent d6b8fd6f15
commit 358b58321a
3 changed files with 9 additions and 8 deletions

View file

@ -1,3 +1,3 @@
#Build Number for ANT. Do not edit!
#Sat Jun 22 09:37:58 CEST 2013
build.number=35
#Thu Aug 01 17:24:24 CEST 2013
build.number=37

View file

@ -15,9 +15,9 @@
<property name="clientsrc.dir" value="${mcp.dir}/src/minecraft"/>
<property name="mc.version" value="1.5.2"/>
<property name="forge.version" value="7.8.0.710"/>
<property name="bc.version" value="3.7.1"/>
<property name="mc.version" value="1.6.2"/>
<property name="forge.version" value="9.10.0.807"/>
<property name="bc.version" value="4.0.0"/>
<property name="bc.version.full" value="${bc.version}"/>
<echo message="Starting build for ${bc.version.full}"/>

View file

@ -71,7 +71,7 @@ public final class PowerHandler {
return current;
}
}
public static final PerditionCalculator DEFUALT_PERDITION = new PerditionCalculator();
public static final PerditionCalculator DEFAULT_PERDITION = new PerditionCalculator();
private float minEnergyReceived;
private float maxEnergyReceived;
private float maxEnergyStored;
@ -90,6 +90,7 @@ public final class PowerHandler {
this.receptor = receptor;
this.type = type;
this.receiver = new PowerReceiver();
this.perdition = DEFAULT_PERDITION;
}
public PowerReceiver getPowerReceiver() {
@ -162,7 +163,7 @@ public final class PowerHandler {
*/
public void setPerdition(PerditionCalculator perdition) {
if (perdition == null)
perdition = DEFUALT_PERDITION;
perdition = DEFAULT_PERDITION;
this.perdition = perdition;
}
@ -191,7 +192,7 @@ public final class PowerHandler {
if (newEnergy == 0 || newEnergy < energyStored)
energyStored = newEnergy;
else
energyStored = DEFUALT_PERDITION.applyPerdition(this, energyStored, perditionTracker.durationOfLastDelay());
energyStored = DEFAULT_PERDITION.applyPerdition(this, energyStored, perditionTracker.durationOfLastDelay());
validateEnergy();
}
}