Skip to content

Commit

Permalink
set idle power usage of expanded interface to a power of four
Browse files Browse the repository at this point in the history
  • Loading branch information
PrototypeTrousers committed Jun 21, 2021
1 parent 42f4ef2 commit aa5d5e3
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ aechannel=stable
aebuild=7
aegroup=appeng
aebasename=appliedenergistics2
trousers=omni-fixes-v21b
trousers=omni-fixes-v43

#########################################################
# Versions #
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/appeng/helpers/DualityInterface.java
Original file line number Diff line number Diff line change
Expand Up @@ -621,6 +621,8 @@ public void dropExcessPatterns()
BlockPos blockPos = this.getLocation().getPos();
Platform.spawnDrops( world, blockPos, dropList );
}

this.gridProxy.setIdlePowerUsage( Math.pow( 4, ( this.getInstalledUpgrades( Upgrades.PATTERN_EXPANSION ) ) ) );
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -680,11 +680,6 @@ private void executeCrafting( final IEnergyGrid eg, final CraftingGridCache cc )
}
}

if (m instanceof DualityInterface )
{
sum *= ( Math.pow( 4, ( (DualityInterface) m ).getInstalledUpgrades( Upgrades.PATTERN_EXPANSION ) ) );
}

// power...
if( eg.extractAEPower( sum, Actionable.MODULATE, PowerMultiplier.CONFIG ) < sum - 0.01 )
{
Expand Down
1 change: 1 addition & 0 deletions src/main/java/appeng/tile/misc/TileInterface.java
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ public void onReady()

super.onReady();
this.duality.initialize();
this.getProxy().setIdlePowerUsage( Math.pow( 4, ( this.getInstalledUpgrades( Upgrades.PATTERN_EXPANSION ) ) ) );
}

@Override
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit aa5d5e3

Please sign in to comment.