More intelligent funneling demand.

This commit is contained in:
AlgorithmX2
2014-06-03 20:33:04 -05:00
parent 09ef3cc231
commit 885bdbf9d5
7 changed files with 24 additions and 10 deletions
+2 -2
View File
@@ -14,14 +14,14 @@ public abstract class RedstoneFlux extends RotaryCraft implements IEnergyHandler
{
if ( simulate )
{
double demand = getExternalPowerDemand( PowerUnits.RF );
double demand = getExternalPowerDemand( PowerUnits.RF, maxReceive );
if ( demand > maxReceive )
return maxReceive;
return (int) Math.floor( maxReceive - demand );
}
else
{
int demand = (int) Math.floor( getExternalPowerDemand( PowerUnits.RF ) );
int demand = (int) Math.floor( getExternalPowerDemand( PowerUnits.RF, maxReceive ) );
int ignored = 0;
int insertAmt = maxReceive;