mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-11-22 15:18:34 +01:00
Made Laser Outputting less unnecessarily for-loopy
This commit is contained in:
parent
f9634ef550
commit
093a69ed13
3 changed files with 11 additions and 6 deletions
|
@ -101,13 +101,13 @@ public class InitBlocks{
|
|||
public static Block blockLaserRelay;
|
||||
|
||||
public static Block blockBlackLotus;
|
||||
//public static Block blockCrystal;
|
||||
public static Block blockCrystal;
|
||||
|
||||
public static void init(){
|
||||
ModUtil.LOGGER.info("Initializing Blocks...");
|
||||
|
||||
//blockCrystal = new BlockCrystal();
|
||||
//BlockUtil.register(blockCrystal, BlockCrystal.TheItemBlock.class);
|
||||
blockCrystal = new BlockCrystal();
|
||||
BlockUtil.register(blockCrystal, BlockCrystal.TheItemBlock.class);
|
||||
|
||||
blockBlackLotus = new BlockBlackLotus();
|
||||
BlockUtil.register(blockBlackLotus);
|
||||
|
|
|
@ -128,13 +128,13 @@ public class InitItems{
|
|||
public static Item itemChestToCrateUpgrade;
|
||||
|
||||
public static Item itemLaserWrench;
|
||||
//public static Item itemCrystal;
|
||||
public static Item itemCrystal;
|
||||
|
||||
public static void init(){
|
||||
ModUtil.LOGGER.info("Initializing Items...");
|
||||
|
||||
//itemCrystal = new ItemCrystal();
|
||||
//ItemUtil.register(itemCrystal);
|
||||
itemCrystal = new ItemCrystal();
|
||||
ItemUtil.register(itemCrystal);
|
||||
|
||||
itemLaserWrench = new ItemLaserWrench();
|
||||
ItemUtil.register(itemLaserWrench);
|
||||
|
|
|
@ -185,6 +185,11 @@ public class LaserRelayConnectionHandler{
|
|||
|
||||
transmitted += ((IEnergyReceiver)tile).receiveEnergy(side.getOpposite(), theoreticalReceived-deduct, simulate);
|
||||
transmitted += deduct;
|
||||
|
||||
//If everything that could be transmitted was transmitted
|
||||
if(transmitted >= maxTransfer){
|
||||
return transmitted;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue