Advertisement
Guest User

Untitled

a guest
Jul 7th, 2012
128
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.84 KB | None | 0 0
  1. package net.minecraft.src;
  2.  
  3. import net.minecraft.src.ic2.api.Direction;
  4. import net.minecraft.src.ic2.api.IEnergySource;
  5. import net.minecraft.src.ic2.api.EnergyNet;
  6.  
  7. public class TileEntityGenTest extends TileEntity implements IEnergySource
  8. {
  9. public boolean added = false;
  10. public TileEntityGenTest()
  11. {
  12. }
  13.  
  14. public void updateEntity()
  15. {
  16. if (added == false)
  17. {
  18. EnergyNet.getForWorld(worldObj).addTileEntity(this);
  19. added = true;
  20. }
  21.  
  22. EnergyNet.getForWorld(worldObj).emitEnergyFrom(this, 32);
  23. }
  24.  
  25. public boolean emitsEnergyTo(TileEntity receiver, Direction direction)
  26. {
  27. return true;
  28. }
  29.  
  30. public boolean isAddedToEnergyNet()
  31. {
  32. return added;
  33. }
  34.  
  35. public int getMaxEnergyOutput()
  36. {
  37. return 32;
  38. }
  39. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement