for (int a = 0; a < pipeList.size(); a++) {
LinkedList<Orientations> theList = getRealPossibleMovements(pipeList.get(a).getPosition());
if (theList.size() > 0) {
for (int b = 0; b < theList.size(); b++) {
Orientations newPos = theList.get(b);
Position destPos = new Position(pipeList.get(a).xCoord, pipeList.get(a).yCoord, pipeList.get(a).zCoord, newPos);
destPos.moveForwards(1.0);
//System.out.println(getPosition().toString() + " RequestEnergy: " + from.toString() + " - Val: " + is + " - Dest: " + destPos.toString());
TileEntity tile = worldObj.getBlockTileEntity((int)destPos.x, (int)destPos.y, (int)destPos.z);
if (tile instanceof TileGenericPipe) {
TileGenericPipe nearbyTile = (TileGenericPipe) tile;
PipeTransportPower nearbyTransport = (PipeTransportPower) nearbyTile.pipe.transport;
nearbyTransport.requestEnergy(newPos.reverse(), is);
}
}
}
}
}