Interface IUpgradeItem

All Known Implementing Classes:
UpgradeItem

public interface IUpgradeItem
Represents an item which can be used as a PneumaticCraft upgrade in machines or other items. You can implement this interface on your own items, or you can use IUpgradeRegistry.makeUpgradeItem(PNCUpgrade, int) to create an upgrade with default PneumaticCraft tooltip behaviour.

Items that you implement yourself should take a Supplier<PNCUpgrade> in their constructor, and store that in a final field. A Supplier is needed because items are registered before PNCUpgrade objects.

  • Method Summary

    Modifier and Type
    Method
    Description
    default int
    Get the tier of this upgrade.
    Return the PNCUpgrade object associated with this item.
  • Method Details

    • getUpgradeType

      PNCUpgrade getUpgradeType()
      Return the PNCUpgrade object associated with this item.
      Returns:
      the PNC upgrade
    • getUpgradeTier

      default int getUpgradeTier()
      Get the tier of this upgrade.
      Returns:
      the upgrade tier