aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/gregtech/api
diff options
context:
space:
mode:
authorGlease <4586901+Glease@users.noreply.github.com>2021-06-11 02:48:50 +0800
committerGlease <4586901+Glease@users.noreply.github.com>2021-07-30 14:38:57 +0800
commit03a45da45fdd85f1276416c2586a98eba79a9b50 (patch)
tree7fc39c0245e3e67d7adfc059e5b59a183b3ad133 /src/main/java/gregtech/api
parent3a472099af01778f5b62cc4ab2aaf6dc5cfff299 (diff)
downloadGT5-Unofficial-03a45da45fdd85f1276416c2586a98eba79a9b50.tar.gz
GT5-Unofficial-03a45da45fdd85f1276416c2586a98eba79a9b50.tar.bz2
GT5-Unofficial-03a45da45fdd85f1276416c2586a98eba79a9b50.zip
migrate all other multis over
Signed-off-by: Glease <4586901+Glease@users.noreply.github.com>
Diffstat (limited to 'src/main/java/gregtech/api')
-rw-r--r--src/main/java/gregtech/api/metatileentity/implementations/GT_MetaTileEntity_EnhancedMultiBlockBase.java11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/main/java/gregtech/api/metatileentity/implementations/GT_MetaTileEntity_EnhancedMultiBlockBase.java b/src/main/java/gregtech/api/metatileentity/implementations/GT_MetaTileEntity_EnhancedMultiBlockBase.java
index d925cc1d84..e4bfef4a48 100644
--- a/src/main/java/gregtech/api/metatileentity/implementations/GT_MetaTileEntity_EnhancedMultiBlockBase.java
+++ b/src/main/java/gregtech/api/metatileentity/implementations/GT_MetaTileEntity_EnhancedMultiBlockBase.java
@@ -144,6 +144,17 @@ public abstract class GT_MetaTileEntity_EnhancedMultiBlockBase<T extends GT_Meta
return (IStructureDefinition<GT_MetaTileEntity_EnhancedMultiBlockBase<T>>) getStructureDefinition();
}
+ /**
+ * Explanation of the world coordinate these offset means:
+ *
+ * Imagine you stand in front of the controller, with controller facing towards you not rotated or flipped.
+ *
+ * The horizontalOffset would be the number of blocks on the left side of the controller, not counting controller itself.
+ * The verticalOffset would be the number of blocks on the top side of the controller, not counting controller itself.
+ * The depthOffset would be the number of blocks between you and controller, not counting controller itself.
+ *
+ * All these offsets can be negative.
+ */
protected final boolean checkPiece(String piece, int horizontalOffset, int verticalOffset, int depthOffset) {
IGregTechTileEntity tTile = getBaseMetaTileEntity();
return getCastedStructureDefinition().check(this, piece, tTile.getWorld(), getExtendedFacing(), tTile.getXCoord(), tTile.getYCoord(), tTile.getZCoord(), horizontalOffset, verticalOffset, depthOffset, !mMachine);