Class ConsumePowerCondition


public class ConsumePowerCondition extends ConsumePower
A power consumer that only activates sometimes.
  • Constructor Details

    • ConsumePowerCondition

      public ConsumePowerCondition(float usage, Boolf<mindustry.gen.Building> consume)
  • Method Details

    • requestedPower

      public float requestedPower(mindustry.gen.Building entity)
      Description copied from class: ConsumePower
      Retrieves the amount of power which is requested for the given block and entity.
      Overrides:
      requestedPower in class ConsumePower
      Parameters:
      entity - The entity which contains the power module.
      Returns:
      The amount of power which is requested per tick.