Class GT5UnofficialAdapter

java.lang.Object
com.gtnewhorizons.horizonqa.api.gt.adapter.GT5UnofficialAdapter
All Implemented Interfaces:
GTAdapter

public final class GT5UnofficialAdapter extends Object implements GTAdapter
GTAdapter targeting GTNH GT5-Unofficial; resolves all reflective lookups at construction time.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    fixAllMaintenanceIssues(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Fix all six maintenance issues on mte immediately.
    getCheckRecipeResultId(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    The string identifier of the last CheckRecipeResult (e.g.
    int
    getEfficiency(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Cleanroom controller efficiency in the 0–10000 range (0.00 %–100.00 %).
    long
    getEUt(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Energy consumed (or produced) per tick for the current recipe.
    int
    getLastParallel(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    The parallel count used during the last recipe check.
    int
    getMaxProgressTime(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Total recipe duration in ticks for the current/last recipe.
    gregtech.api.interfaces.tileentity.IGregTechTileEntity
    getOutputHatchTE(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte, int index)
    Returns the N-th fluid output hatch tile entity.
    long
    getPollution(net.minecraft.world.chunk.Chunk chunk)
    Pollution units accumulated in chunk.
    int
    getProgressTime(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Current recipe progress in ticks.
    long
    getRecipesDone(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Total number of recipes completed since the machine was placed.
    int
    getRepairStatus(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Number of maintenance issues that have been repaired, in the range 0–6 (where 6 means fully maintained).
    long
    getStoredEU(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    EU currently stored in the machine's internal energy buffer.
    boolean
    isActive(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Whether the multi-block is currently processing a recipe (i.e.
    boolean
    isStructureFormed(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Whether the multi-block structure is fully formed.
    void
    rotateStructureTileNbt(net.minecraft.nbt.NBTTagCompound nbt, int rotation)
    Rotate GT tile entity fields stored in exported structure NBT.
    snapshotHatches(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Sizes of the standard hatch lists.
    snapshotMaintenance(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Bitmask of the six maintenance flags.
    snapshotRecipeState(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
    Bundled recipe-state read used by the warp differ.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • GT5UnofficialAdapter

      public GT5UnofficialAdapter()
  • Method Details

    • getPollution

      public long getPollution(net.minecraft.world.chunk.Chunk chunk)
      Description copied from interface: GTAdapter
      Pollution units accumulated in chunk.
      Specified by:
      getPollution in interface GTAdapter
    • isStructureFormed

      public boolean isStructureFormed(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Whether the multi-block structure is fully formed.
      Specified by:
      isStructureFormed in interface GTAdapter
    • isActive

      public boolean isActive(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Whether the multi-block is currently processing a recipe (i.e. mMaxProgresstime > 0).
      Specified by:
      isActive in interface GTAdapter
    • getProgressTime

      public int getProgressTime(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Current recipe progress in ticks.
      Specified by:
      getProgressTime in interface GTAdapter
    • getMaxProgressTime

      public int getMaxProgressTime(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Total recipe duration in ticks for the current/last recipe.
      Specified by:
      getMaxProgressTime in interface GTAdapter
    • getEUt

      public long getEUt(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Energy consumed (or produced) per tick for the current recipe. Negative values indicate consumption, positive values indicate generation. Returned as long because MTEExtendedPowerMultiBlockBase subclasses (EBF, fusion, etc.) use a long-backed energy field that can exceed int range.
      Specified by:
      getEUt in interface GTAdapter
    • getEfficiency

      public int getEfficiency(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Cleanroom controller efficiency in the 0–10000 range (0.00 %–100.00 %).
      Specified by:
      getEfficiency in interface GTAdapter
    • getStoredEU

      public long getStoredEU(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      EU currently stored in the machine's internal energy buffer.
      Specified by:
      getStoredEU in interface GTAdapter
    • getRepairStatus

      public int getRepairStatus(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Number of maintenance issues that have been repaired, in the range 0–6 (where 6 means fully maintained).
      Specified by:
      getRepairStatus in interface GTAdapter
    • fixAllMaintenanceIssues

      public void fixAllMaintenanceIssues(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Fix all six maintenance issues on mte immediately. Useful in test set-up to skip the maintenance requirement.
      Specified by:
      fixAllMaintenanceIssues in interface GTAdapter
    • getRecipesDone

      public long getRecipesDone(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Total number of recipes completed since the machine was placed.
      Specified by:
      getRecipesDone in interface GTAdapter
    • getLastParallel

      public int getLastParallel(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      The parallel count used during the last recipe check. Returns 0 when no recipe has been processed yet.
      Specified by:
      getLastParallel in interface GTAdapter
    • getCheckRecipeResultId

      public String getCheckRecipeResultId(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      The string identifier of the last CheckRecipeResult (e.g. "success", "no_recipe", …). Never null.
      Specified by:
      getCheckRecipeResultId in interface GTAdapter
    • snapshotRecipeState

      public RecipeStateSnapshot snapshotRecipeState(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Bundled recipe-state read used by the warp differ. Single call to minimise per-tick polling cost.
      Specified by:
      snapshotRecipeState in interface GTAdapter
    • snapshotMaintenance

      public MaintenanceSnapshot snapshotMaintenance(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Bitmask of the six maintenance flags. A set bit means the issue is currently present.
      Specified by:
      snapshotMaintenance in interface GTAdapter
    • snapshotHatches

      public HatchTopology snapshotHatches(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte)
      Description copied from interface: GTAdapter
      Sizes of the standard hatch lists. Used for MachineFormed event payloads.
      Specified by:
      snapshotHatches in interface GTAdapter
    • getOutputHatchTE

      public gregtech.api.interfaces.tileentity.IGregTechTileEntity getOutputHatchTE(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte, int index)
      Returns the N-th fluid output hatch tile entity. For multiblocks that store output hatches in a non-standard per-layer field (the Distillation Tower uses mOutputHatchesByLayer), this indexes layers and returns the first hatch in that layer. Falls back to the standard mOutputHatches list for all other multiblocks.
      Specified by:
      getOutputHatchTE in interface GTAdapter
    • rotateStructureTileNbt

      public void rotateStructureTileNbt(net.minecraft.nbt.NBTTagCompound nbt, int rotation)
      Description copied from interface: GTAdapter
      Rotate GT tile entity fields stored in exported structure NBT.
      Specified by:
      rotateStructureTileNbt in interface GTAdapter