Implemented 5% Tunnel Tax.

This commit is contained in:
AlgorithmX2
2014-05-02 00:40:46 -05:00
parent da764470a4
commit cc8c3bb75e
6 changed files with 32 additions and 14 deletions
+2 -2
View File
@@ -25,7 +25,7 @@ public class AEConfig extends Configuration implements IConfigureableObject, ICo
public static AEConfig instance;
public static float TunnelPowerLoss = 0.05f;
public static double TunnelPowerLoss = 0.05;
public String latestVersion = VERSION;
public long latestTimeStamp = 0;
@@ -267,7 +267,7 @@ public class AEConfig extends Configuration implements IConfigureableObject, ICo
min = Math.max( min, thisInt + 1 );
}
if ( alreadyUsed )
{
if ( min < 16383 )
@@ -80,16 +80,19 @@ public class P2PTunnelRegistry implements IP2PTunnelRegistry
@Override
public TunnelType getTunnelTypeByItem(ItemStack trigger)
{
if ( FluidContainerRegistry.isContainer( trigger ) )
return TunnelType.FLUID;
for (ItemStack is : Tunnels.keySet())
if ( trigger != null )
{
if ( is.getItem() == trigger.getItem() && is.getItemDamage() == OreDictionary.WILDCARD_VALUE )
return Tunnels.get( is );
if ( FluidContainerRegistry.isContainer( trigger ) )
return TunnelType.FLUID;
if ( Platform.isSameItem( is, trigger ) )
return Tunnels.get( is );
for (ItemStack is : Tunnels.keySet())
{
if ( is.getItem() == trigger.getItem() && is.getItemDamage() == OreDictionary.WILDCARD_VALUE )
return Tunnels.get( is );
if ( Platform.isSameItem( is, trigger ) )
return Tunnels.get( is );
}
}
return null;