Mekanism-tilera-Edition/common/ic2/api/energy/tile/IEnergySource.java

27 lines
651 B
Java
Raw Normal View History

2013-04-13 16:35:13 +02:00
package ic2.api.energy.tile;
/**
* Allows a tile entity (mostly a generator) to emit energy.
*
* See ic2/api/energy/usage.txt for an overall description of the energy net api.
2013-04-13 16:35:13 +02:00
*/
public interface IEnergySource extends IEnergyEmitter {
/**
* Energy output provided by the source this tick.
* This is typically Math.min(stored energy, max output/tick).
2013-04-13 16:35:13 +02:00
*
* @return Energy offered this tick
2013-04-13 16:35:13 +02:00
*/
double getOfferedEnergy();
/**
* Draw energy from this source's buffer.
*
* If the source doesn't have a buffer, this is a no-op.
*
2013-08-30 00:57:13 +02:00
* @param amount amount of EU to draw, may be negative
*/
void drawEnergy(double amount);
2013-04-13 16:35:13 +02:00
}