mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-11-06 00:49:09 +01:00
made laser relays not try to input back into the thing they got energy from
This commit is contained in:
parent
2cc5d02814
commit
d8af7636ee
2 changed files with 12 additions and 0 deletions
|
@ -123,7 +123,13 @@ public class TileEntityLaserRelayEnergy extends TileEntityLaserRelay implements
|
|||
TileEntity relayTile = this.worldObj.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;
|
||||
|
|
|
@ -117,7 +117,13 @@ public class TileEntityLaserRelayFluids extends TileEntityLaserRelay implements
|
|||
TileEntity relayTile = this.worldObj.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