mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-11-26 00:38:35 +01:00
Made Laser Relays not try to input back into the thing they got energy from
Closes #425
This commit is contained in:
parent
cfd6506eb3
commit
fba447376b
2 changed files with 12 additions and 0 deletions
|
@ -147,7 +147,13 @@ public class TileEntityLaserRelayEnergy extends TileEntityLaserRelay{
|
|||
TileEntity relayTile = this.world.getTileEntity(relay);
|
||||
if(relayTile instanceof TileEntityLaserRelayEnergy){
|
||||
TileEntityLaserRelayEnergy theRelay = (TileEntityLaserRelayEnergy)relayTile;
|
||||
|
||||
int amount = theRelay.receiversAround.size();
|
||||
if(theRelay == this && theRelay.receiversAround.containsKey(from)){
|
||||
//So that the tile energy was gotten from isn't factored into the amount
|
||||
amount--;
|
||||
}
|
||||
|
||||
if(amount > 0){
|
||||
relaysThatWork.add(theRelay);
|
||||
totalReceiverAmount += amount;
|
||||
|
|
|
@ -143,7 +143,13 @@ public class TileEntityLaserRelayFluids extends TileEntityLaserRelay implements
|
|||
TileEntity relayTile = this.world.getTileEntity(relay);
|
||||
if(relayTile instanceof TileEntityLaserRelayFluids){
|
||||
TileEntityLaserRelayFluids theRelay = (TileEntityLaserRelayFluids)relayTile;
|
||||
|
||||
int amount = theRelay.receiversAround.size();
|
||||
if(theRelay == this && theRelay.receiversAround.containsKey(from)){
|
||||
//So that the tile energy was gotten from isn't factored into the amount
|
||||
amount--;
|
||||
}
|
||||
|
||||
if(amount > 0){
|
||||
relaysThatWork.add(theRelay);
|
||||
totalReceiverAmount += amount;
|
||||
|
|
Loading…
Reference in a new issue