Class GT5UnofficialAdapter
java.lang.Object
com.gtnewhorizons.horizonqa.api.gt.adapter.GT5UnofficialAdapter
- All Implemented Interfaces:
GTAdapter
GTAdapter targeting GTNH GT5-Unofficial; resolves all reflective lookups at construction time.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidfixAllMaintenanceIssues(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Fix all six maintenance issues onmteimmediately.getCheckRecipeResultId(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) The string identifier of the lastCheckRecipeResult(e.g.intgetEfficiency(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Cleanroom controller efficiency in the 0–10000 range (0.00 %–100.00 %).longgetEUt(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Energy consumed (or produced) per tick for the current recipe.intgetLastParallel(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) The parallel count used during the last recipe check.intgetMaxProgressTime(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Total recipe duration in ticks for the current/last recipe.gregtech.api.interfaces.tileentity.IGregTechTileEntitygetOutputHatchTE(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte, int index) Returns the N-th fluid output hatch tile entity.longgetPollution(net.minecraft.world.chunk.Chunk chunk) Pollution units accumulated inchunk.intgetProgressTime(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Current recipe progress in ticks.longgetRecipesDone(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Total number of recipes completed since the machine was placed.intgetRepairStatus(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Number of maintenance issues that have been repaired, in the range 0–6 (where 6 means fully maintained).longgetStoredEU(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) EU currently stored in the machine's internal energy buffer.booleanisActive(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Whether the multi-block is currently processing a recipe (i.e.booleanisStructureFormed(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Whether the multi-block structure is fully formed.voidrotateStructureTileNbt(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.
-
Constructor Details
-
GT5UnofficialAdapter
public GT5UnofficialAdapter()
-
-
Method Details
-
getPollution
public long getPollution(net.minecraft.world.chunk.Chunk chunk) Description copied from interface:GTAdapterPollution units accumulated inchunk.- Specified by:
getPollutionin interfaceGTAdapter
-
isStructureFormed
public boolean isStructureFormed(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterWhether the multi-block structure is fully formed.- Specified by:
isStructureFormedin interfaceGTAdapter
-
isActive
public boolean isActive(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterWhether the multi-block is currently processing a recipe (i.e.mMaxProgresstime > 0). -
getProgressTime
public int getProgressTime(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterCurrent recipe progress in ticks.- Specified by:
getProgressTimein interfaceGTAdapter
-
getMaxProgressTime
public int getMaxProgressTime(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterTotal recipe duration in ticks for the current/last recipe.- Specified by:
getMaxProgressTimein interfaceGTAdapter
-
getEUt
public long getEUt(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterEnergy consumed (or produced) per tick for the current recipe. Negative values indicate consumption, positive values indicate generation. Returned aslongbecauseMTEExtendedPowerMultiBlockBasesubclasses (EBF, fusion, etc.) use along-backed energy field that can exceedintrange. -
getEfficiency
public int getEfficiency(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterCleanroom controller efficiency in the 0–10000 range (0.00 %–100.00 %).- Specified by:
getEfficiencyin interfaceGTAdapter
-
getStoredEU
public long getStoredEU(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterEU currently stored in the machine's internal energy buffer.- Specified by:
getStoredEUin interfaceGTAdapter
-
getRepairStatus
public int getRepairStatus(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterNumber of maintenance issues that have been repaired, in the range 0–6 (where 6 means fully maintained).- Specified by:
getRepairStatusin interfaceGTAdapter
-
fixAllMaintenanceIssues
public void fixAllMaintenanceIssues(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterFix all six maintenance issues onmteimmediately. Useful in test set-up to skip the maintenance requirement.- Specified by:
fixAllMaintenanceIssuesin interfaceGTAdapter
-
getRecipesDone
public long getRecipesDone(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterTotal number of recipes completed since the machine was placed.- Specified by:
getRecipesDonein interfaceGTAdapter
-
getLastParallel
public int getLastParallel(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterThe parallel count used during the last recipe check. Returns 0 when no recipe has been processed yet.- Specified by:
getLastParallelin interfaceGTAdapter
-
getCheckRecipeResultId
Description copied from interface:GTAdapterThe string identifier of the lastCheckRecipeResult(e.g."success","no_recipe", …). Nevernull.- Specified by:
getCheckRecipeResultIdin interfaceGTAdapter
-
snapshotRecipeState
public RecipeStateSnapshot snapshotRecipeState(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterBundled recipe-state read used by the warp differ. Single call to minimise per-tick polling cost.- Specified by:
snapshotRecipeStatein interfaceGTAdapter
-
snapshotMaintenance
public MaintenanceSnapshot snapshotMaintenance(gregtech.api.interfaces.metatileentity.IMetaTileEntity mte) Description copied from interface:GTAdapterBitmask of the six maintenance flags. A set bit means the issue is currently present.- Specified by:
snapshotMaintenancein interfaceGTAdapter
-
snapshotHatches
Description copied from interface:GTAdapterSizes of the standard hatch lists. Used forMachineFormedevent payloads.- Specified by:
snapshotHatchesin interfaceGTAdapter
-
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 usesmOutputHatchesByLayer), this indexes layers and returns the first hatch in that layer. Falls back to the standardmOutputHatcheslist for all other multiblocks.- Specified by:
getOutputHatchTEin interfaceGTAdapter
-
rotateStructureTileNbt
public void rotateStructureTileNbt(net.minecraft.nbt.NBTTagCompound nbt, int rotation) Description copied from interface:GTAdapterRotate GT tile entity fields stored in exported structure NBT.- Specified by:
rotateStructureTileNbtin interfaceGTAdapter
-