Interface EnergyNetProvider

All Superinterfaces:
EnergyNetComponent, ItemAttribute
All Known Implementing Classes:
AbstractEnergyProvider, AGenerator, BioGenerator, CoalGenerator, CombustionGenerator, LavaGenerator, MagnesiumGenerator, NetherStarReactor, NuclearReactor, Reactor, SolarGenerator

public interface EnergyNetProvider extends EnergyNetComponent
An EnergyNetProvider is an extension of EnergyNetComponent which provides energy to an EnergyNet. It must be implemented on any Generator or Reactor.
Author:
TheBusyBiscuit
See Also:
  • Method Details

    • getEnergyComponentType

      @Nonnull default EnergyNetComponentType getEnergyComponentType()
      Description copied from interface: EnergyNetComponent
      This method returns the Type of EnergyNetComponentType this SlimefunItem represents. It describes how this Block will interact with an EnergyNet.
      Specified by:
      getEnergyComponentType in interface EnergyNetComponent
      Returns:
      The EnergyNetComponentType this SlimefunItem represents.
    • getGeneratedOutput

      default int getGeneratedOutput(@Nonnull org.bukkit.Location l, @Nonnull SlimefunBlockData data)
      This method returns how much energy this EnergyNetProvider provides to the EnergyNet. We call this method on every tick, so make sure to keep it light and fast. Stored energy does not have to be handled in here.
      Parameters:
      l - The Location of this EnergyNetProvider
      data - The stored block data
      Returns:
      The generated output energy of this EnergyNetProvider.
    • getGeneratedOutput

      default int getGeneratedOutput(@Nonnull org.bukkit.Location l, @Nonnull Config data)
    • willExplode

      default boolean willExplode(@Nonnull org.bukkit.Location l, @Nonnull SlimefunBlockData data)
      This method returns whether the given Location is going to explode on the next tick.
      Parameters:
      l - The Location of this EnergyNetProvider
      data - The stored block data
      Returns:
      Whether or not this Location will explode.
    • willExplode

      default boolean willExplode(@Nonnull org.bukkit.Location l, @Nonnull Config data)