Package net.minecraft.core
Class BlockPos
java.lang.Object
net.minecraft.core.Vec3i
net.minecraft.core.BlockPos
- All Implemented Interfaces:
- Comparable<Vec3i>
- Direct Known Subclasses:
- BlockPos.MutableBlockPos
- 
Nested Class SummaryNested Classes
- 
Field SummaryFieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<BlockPos>private static final org.slf4j.Loggerprivate static final intprivate static final longstatic final intprivate static final longprivate static final intprivate static final longprivate static final intprivate static final intprivate static final intstatic final BlockPos
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionabove()above(int p_121972_) longasLong()static longasLong(int p_121883_, int p_121884_, int p_121885_) atY(int p_175289_) below()below(int p_122000_) betweenClosed(int p_121977_, int p_121978_, int p_121979_, int p_121980_, int p_121981_, int p_121982_) betweenClosed(BlockPos p_121941_, BlockPos p_121942_) betweenClosedStream(int p_121887_, int p_121888_, int p_121889_, int p_121890_, int p_121891_, int p_121892_) betweenClosedStream(BlockPos p_121991_, BlockPos p_121992_) betweenClosedStream(BoundingBox p_121920_) betweenClosedStream(AABB p_121922_) static intbreadthFirstTraversal(BlockPos p_278078_, int p_277385_, int p_277666_, BiConsumer<BlockPos, Consumer<BlockPos>> p_277755_, Predicate<BlockPos> p_278094_) static BlockPoscontaining(double p_275310_, double p_275414_, double p_275737_) static BlockPoscontaining(Position p_275443_) east()east(int p_122031_) findClosestMatch(BlockPos p_121931_, int p_121932_, int p_121933_, Predicate<BlockPos> p_121934_) static longgetFlatIndex(long p_122028_) static intgetX(long p_121984_) static intgetY(long p_122009_) static intgetZ(long p_122016_) multiply(int p_175263_) mutable()north()north(int p_122014_) static BlockPosof(long p_122023_) offset(int p_121973_, int p_121974_, int p_121975_) static longoffset(long p_121911_, int p_121912_, int p_121913_, int p_121914_) static longrandomBetweenClosed(RandomSource p_235642_, int p_235643_, int p_235644_, int p_235645_, int p_235646_, int p_235647_, int p_235648_, int p_235649_) randomInCube(RandomSource p_235651_, int p_235652_, BlockPos p_235653_, int p_235654_) relative(Direction.Axis p_121943_, int p_121944_) south()south(int p_122021_) static Iterable<BlockPos.MutableBlockPos>spiralAround(BlockPos p_121936_, int p_121937_, Direction p_121938_, Direction p_121939_) squareOutSouthEast(BlockPos p_284978_) Deprecated.west()west(int p_122026_) withinManhattan(BlockPos p_121926_, int p_121927_, int p_121928_, int p_121929_) withinManhattanStream(BlockPos p_121986_, int p_121987_, int p_121988_, int p_121989_) Methods inherited from class net.minecraft.core.Vec3icloserThan, closerToCenterThan, compareTo, distManhattan, distSqr, distToCenterSqr, distToCenterSqr, distToLowCornerSqr, equals, get, getX, getY, getZ, hashCode, offsetCodec, setX, setY, setZ, toShortString, toString
- 
Field Details- 
CODEC
- 
LOGGERprivate static final org.slf4j.Logger LOGGER
- 
ZERO
- 
PACKED_X_LENGTHprivate static final int PACKED_X_LENGTH
- 
PACKED_Z_LENGTHprivate static final int PACKED_Z_LENGTH
- 
PACKED_Y_LENGTHpublic static final int PACKED_Y_LENGTH
- 
PACKED_X_MASKprivate static final long PACKED_X_MASK
- 
PACKED_Y_MASKprivate static final long PACKED_Y_MASK
- 
PACKED_Z_MASKprivate static final long PACKED_Z_MASK
- 
Y_OFFSETprivate static final int Y_OFFSET- See Also:
 
- 
Z_OFFSETprivate static final int Z_OFFSET
- 
X_OFFSETprivate static final int X_OFFSET
 
- 
- 
Constructor Details- 
BlockPospublic BlockPos(int p_121869_, int p_121870_, int p_121871_) 
- 
BlockPos
 
- 
- 
Method Details- 
offset
- 
offsetpublic static long offset(long p_121911_, int p_121912_, int p_121913_, int p_121914_) 
- 
getXpublic static int getX(long p_121984_) 
- 
getYpublic static int getY(long p_122009_) 
- 
getZpublic static int getZ(long p_122016_) 
- 
of
- 
containing
- 
containing
- 
asLongpublic long asLong()
- 
asLongpublic static long asLong(int p_121883_, int p_121884_, int p_121885_) 
- 
getFlatIndexpublic static long getFlatIndex(long p_122028_) 
- 
offset
- 
getCenter
- 
offset
- 
subtract
- 
multiply
- 
above
- 
above
- 
below
- 
below
- 
north
- 
north
- 
south
- 
south
- 
west
- 
west
- 
east
- 
east
- 
relative
- 
relative
- 
relative
- 
rotate
- 
cross
- 
atY
- 
immutable
- 
mutable
- 
randomInCubepublic static Iterable<BlockPos> randomInCube(RandomSource p_235651_, int p_235652_, BlockPos p_235653_, int p_235654_) 
- 
squareOutSouthEastDeprecated.
- 
randomBetweenClosedpublic static Iterable<BlockPos> randomBetweenClosed(RandomSource p_235642_, int p_235643_, int p_235644_, int p_235645_, int p_235646_, int p_235647_, int p_235648_, int p_235649_) 
- 
withinManhattan
- 
findClosestMatch
- 
withinManhattanStream
- 
betweenClosed
- 
betweenClosedStream
- 
betweenClosedStream
- 
betweenClosedStream
- 
betweenClosedStream
- 
betweenClosed
- 
spiralAroundpublic static Iterable<BlockPos.MutableBlockPos> spiralAround(BlockPos p_121936_, int p_121937_, Direction p_121938_, Direction p_121939_) 
- 
breadthFirstTraversal
 
-