类 BlockPos
- java.lang.Object
-
- net.minecraft.util.math.Vec3i
-
- net.minecraft.util.math.BlockPos
-
- 所有已实现的接口:
Comparable<Vec3i>
- 直接已知子类:
BlockPos.Mutable
@Unmodifiable public class BlockPos extends Vec3i
Represents the position of a block in a three-dimensional volume.The position is integer-valued.
A block position may be mutable; hence, when using block positions obtained from other places as map keys, etc., you should call
toImmutable()to obtain an immutable block position.- Mappings:
Namespace Name official gbintermediary net/minecraft/class_2338named net/minecraft/util/math/BlockPos
-
-
嵌套类概要
嵌套类 修饰符和类型 类 说明 static classBlockPos.Mutable
-
字段概要
字段 修饰符和类型 字段 说明 private static intBIT_SHIFT_Xprivate static intBIT_SHIFT_Zprivate static longBITS_Xprivate static longBITS_Yprivate static longBITS_Zstatic com.mojang.serialization.Codec<BlockPos>CODECprivate static intfield_33083private static LoggerLOGGERstatic BlockPosORIGINThe block position which x, y, and z values are all zero.private static intSIZE_BITS_Xstatic intSIZE_BITS_Yprivate static intSIZE_BITS_Z
-
方法概要
所有方法 静态方法 实例方法 具体方法 修饰符和类型 方法 说明 BlockPosadd(double double2, double double3, double double4)BlockPosadd(int int2, int int3, int int4)Returns another Vec3i whose coordinates have the parameter x, y, and z added to the coordinates of this vector.static longadd(long value, int x, int y, int z)BlockPosadd(Vec3i vec3i)longasLong()static longasLong(int x, int y, int z)BlockPoscrossProduct(Vec3i pos)BlockPosdown()BlockPosdown(int int2)BlockPoseast()BlockPoseast(int distance)static Optional<BlockPos>findClosest(BlockPos pos, int horizontalRange, int verticalRange, Predicate<BlockPos> condition)static BlockPosfromLong(long packedPos)static Iterable<BlockPos>iterate(int startX, int startY, int startZ, int endX, int endY, int endZ)static Iterable<BlockPos>iterate(BlockPos start, BlockPos end)static Iterable<BlockPos.Mutable>iterateInSquare(BlockPos center, int radius, Direction firstDirection, Direction secondDirection)Iterates block positions around thecenterin a square of (2 * radius + 1) by (2 * radius + 1).static Iterable<BlockPos>iterateOutwards(BlockPos center, int xRange, int yRange, int zRange)Iterates block positions around thecenter.static Iterable<BlockPos>iterateRandomly(Random random, int count, int minX, int minY, int minZ, int maxX, int maxY, int maxZ)Iterates throughcountrandom block positions in the given area.static Iterable<BlockPos>iterateRandomly(Random random, int count, BlockPos around, int range)Iterates throughcountrandom block positions in a given range around the given position.BlockPosmultiply(int int2)BlockPos.MutablemutableCopy()Returns a mutable copy of this block position.BlockPosnorth()BlockPosnorth(int distance)static longoffset(long value, Direction direction)BlockPosoffset(Direction direction)BlockPosoffset(Direction.Axis axis, int int2)BlockPosoffset(Direction direction, int int2)static longremoveChunkSectionLocalY(long y)BlockPosrotate(BlockRotation rotation)BlockPossouth()BlockPossouth(int distance)static Stream<BlockPos>stream(int startX, int startY, int startZ, int endX, int endY, int endZ)static Stream<BlockPos>stream(BlockBox box)static Stream<BlockPos>stream(BlockPos start, BlockPos end)static Stream<BlockPos>stream(Box box)static Stream<BlockPos>streamOutwards(BlockPos center, int maxX, int maxY, int maxZ)BlockPossubtract(Vec3i vec3i)BlockPostoImmutable()Returns an immutable block position with the same x, y, and z as this position.static intunpackLongX(long packedPos)static intunpackLongY(long packedPos)static intunpackLongZ(long packedPos)BlockPosup()BlockPosup(int distance)BlockPoswest()BlockPoswest(int distance)BlockPoswithY(int y)-
从类继承的方法 net.minecraft.util.math.Vec3i
compareTo, equals, getComponentAlongAxis, getManhattanDistance, getSquaredDistance, getSquaredDistance, getSquaredDistance, getSquaredDistance, getX, getY, getZ, hashCode, isWithinDistance, isWithinDistance, setX, setY, setZ, toShortString, toString
-
-
-
-
字段详细资料
-
CODEC
public static final com.mojang.serialization.Codec<BlockPos> CODEC
- Mappings:
Namespace Name Mixin selector official aLgb;a:Lcom/mojang/serialization/Codec;intermediary field_25064Lnet/minecraft/class_2338;field_25064:Lcom/mojang/serialization/Codec;named CODECLnet/minecraft/util/math/BlockPos;CODEC:Lcom/mojang/serialization/Codec;
-
LOGGER
private static final Logger LOGGER
- Mappings:
Namespace Name Mixin selector official dLgb;d:Lorg/apache/logging/log4j/Logger;intermediary field_18789Lnet/minecraft/class_2338;field_18789:Lorg/apache/logging/log4j/Logger;named LOGGERLnet/minecraft/util/math/BlockPos;LOGGER:Lorg/apache/logging/log4j/Logger;
-
ORIGIN
public static final BlockPos ORIGIN
The block position which x, y, and z values are all zero.- Mappings:
Namespace Name Mixin selector official bLgb;b:Lgb;intermediary field_10980Lnet/minecraft/class_2338;field_10980:Lnet/minecraft/class_2338;named ORIGINLnet/minecraft/util/math/BlockPos;ORIGIN:Lnet/minecraft/util/math/BlockPos;
-
SIZE_BITS_X
private static final int SIZE_BITS_X
- Mappings:
Namespace Name Mixin selector official gLgb;g:Iintermediary field_10978Lnet/minecraft/class_2338;field_10978:Inamed SIZE_BITS_XLnet/minecraft/util/math/BlockPos;SIZE_BITS_X:I
-
SIZE_BITS_Z
private static final int SIZE_BITS_Z
- Mappings:
Namespace Name Mixin selector official hLgb;h:Iintermediary field_10977Lnet/minecraft/class_2338;field_10977:Inamed SIZE_BITS_ZLnet/minecraft/util/math/BlockPos;SIZE_BITS_Z:I
-
SIZE_BITS_Y
public static final int SIZE_BITS_Y
- Mappings:
Namespace Name Mixin selector official cLgb;c:Iintermediary field_10975Lnet/minecraft/class_2338;field_10975:Inamed SIZE_BITS_YLnet/minecraft/util/math/BlockPos;SIZE_BITS_Y:I
-
BITS_X
private static final long BITS_X
- Mappings:
Namespace Name Mixin selector official iLgb;i:Jintermediary field_10976Lnet/minecraft/class_2338;field_10976:Jnamed BITS_XLnet/minecraft/util/math/BlockPos;BITS_X:J
-
BITS_Y
private static final long BITS_Y
- Mappings:
Namespace Name Mixin selector official jLgb;j:Jintermediary field_10974Lnet/minecraft/class_2338;field_10974:Jnamed BITS_YLnet/minecraft/util/math/BlockPos;BITS_Y:J
-
BITS_Z
private static final long BITS_Z
- Mappings:
Namespace Name Mixin selector official kLgb;k:Jintermediary field_10973Lnet/minecraft/class_2338;field_10973:Jnamed BITS_ZLnet/minecraft/util/math/BlockPos;BITS_Z:J
-
field_33083
private static final int field_33083
- 另请参阅:
- 常量字段值
- Mappings:
Namespace Name Mixin selector official lLgb;l:Iintermediary field_33083Lnet/minecraft/class_2338;field_33083:Inamed field_33083Lnet/minecraft/util/math/BlockPos;field_33083:I
-
BIT_SHIFT_Z
private static final int BIT_SHIFT_Z
- Mappings:
Namespace Name Mixin selector official mLgb;m:Iintermediary field_10983Lnet/minecraft/class_2338;field_10983:Inamed BIT_SHIFT_ZLnet/minecraft/util/math/BlockPos;BIT_SHIFT_Z:I
-
BIT_SHIFT_X
private static final int BIT_SHIFT_X
- Mappings:
Namespace Name Mixin selector official nLgb;n:Iintermediary field_10981Lnet/minecraft/class_2338;field_10981:Inamed BIT_SHIFT_XLnet/minecraft/util/math/BlockPos;BIT_SHIFT_X:I
-
-
构造器详细资料
-
BlockPos
public BlockPos(int x, int y, int z)- Mappings:
Namespace Name Mixin selector official <init>Lgw;<init>(III)Vintermediary <init>Lnet/minecraft/class_2382;<init>(III)Vnamed <init>Lnet/minecraft/util/math/Vec3i;<init>(III)V
-
BlockPos
public BlockPos(double x, double y, double z)- Mappings:
Namespace Name Mixin selector official <init>Lgw;<init>(DDD)Vintermediary <init>Lnet/minecraft/class_2382;<init>(DDD)Vnamed <init>Lnet/minecraft/util/math/Vec3i;<init>(DDD)V
-
BlockPos
public BlockPos(Vec3d pos)
- Mappings:
Namespace Name Mixin selector official <init>Lgb;<init>(Ldma;)Vintermediary <init>Lnet/minecraft/class_2338;<init>(Lnet/minecraft/class_243;)Vnamed <init>Lnet/minecraft/util/math/BlockPos;<init>(Lnet/minecraft/util/math/Vec3d;)V
-
BlockPos
public BlockPos(Position pos)
- Mappings:
Namespace Name Mixin selector official <init>Lgb;<init>(Lgo;)Vintermediary <init>Lnet/minecraft/class_2338;<init>(Lnet/minecraft/class_2374;)Vnamed <init>Lnet/minecraft/util/math/BlockPos;<init>(Lnet/minecraft/util/math/Position;)V
-
BlockPos
public BlockPos(Vec3i pos)
- Mappings:
Namespace Name Mixin selector official <init>Lgb;<init>(Lgw;)Vintermediary <init>Lnet/minecraft/class_2338;<init>(Lnet/minecraft/class_2382;)Vnamed <init>Lnet/minecraft/util/math/BlockPos;<init>(Lnet/minecraft/util/math/Vec3i;)V
-
-
方法详细资料
-
offset
public static long offset(long value, Direction direction)- Mappings:
Namespace Name Mixin selector official aLgb;a(JLgg;)Jintermediary method_10060Lnet/minecraft/class_2338;method_10060(JLnet/minecraft/class_2350;)Jnamed offsetLnet/minecraft/util/math/BlockPos;offset(JLnet/minecraft/util/math/Direction;)J
-
add
public static long add(long value, int x, int y, int z)- Mappings:
Namespace Name Mixin selector official aLgb;a(JIII)Jintermediary method_10096Lnet/minecraft/class_2338;method_10096(JIII)Jnamed addLnet/minecraft/util/math/BlockPos;add(JIII)J
-
unpackLongX
public static int unpackLongX(long packedPos)
- Mappings:
Namespace Name Mixin selector official aLgb;a(J)Iintermediary method_10061Lnet/minecraft/class_2338;method_10061(J)Inamed unpackLongXLnet/minecraft/util/math/BlockPos;unpackLongX(J)I
-
unpackLongY
public static int unpackLongY(long packedPos)
- Mappings:
Namespace Name Mixin selector official bLgb;b(J)Iintermediary method_10071Lnet/minecraft/class_2338;method_10071(J)Inamed unpackLongYLnet/minecraft/util/math/BlockPos;unpackLongY(J)I
-
unpackLongZ
public static int unpackLongZ(long packedPos)
- Mappings:
Namespace Name Mixin selector official cLgb;c(J)Iintermediary method_10083Lnet/minecraft/class_2338;method_10083(J)Inamed unpackLongZLnet/minecraft/util/math/BlockPos;unpackLongZ(J)I
-
fromLong
public static BlockPos fromLong(long packedPos)
- Mappings:
Namespace Name Mixin selector official dLgb;d(J)Lgb;intermediary method_10092Lnet/minecraft/class_2338;method_10092(J)Lnet/minecraft/class_2338;named fromLongLnet/minecraft/util/math/BlockPos;fromLong(J)Lnet/minecraft/util/math/BlockPos;
-
asLong
public long asLong()
- Mappings:
Namespace Name Mixin selector official aLgb;a()Jintermediary method_10063Lnet/minecraft/class_2338;method_10063()Jnamed asLongLnet/minecraft/util/math/BlockPos;asLong()J
-
asLong
public static long asLong(int x, int y, int z)- Mappings:
Namespace Name Mixin selector official aLgb;a(III)Jintermediary method_10064Lnet/minecraft/class_2338;method_10064(III)Jnamed asLongLnet/minecraft/util/math/BlockPos;asLong(III)J
-
removeChunkSectionLocalY
public static long removeChunkSectionLocalY(long y)
- Mappings:
Namespace Name Mixin selector official eLgb;e(J)Jintermediary method_10091Lnet/minecraft/class_2338;method_10091(J)Jnamed removeChunkSectionLocalYLnet/minecraft/util/math/BlockPos;removeChunkSectionLocalY(J)J
-
add
public BlockPos add(double double2, double double3, double double4)
-
add
public BlockPos add(int int2, int int3, int int4)
从类复制的说明:Vec3iReturns another Vec3i whose coordinates have the parameter x, y, and z added to the coordinates of this vector.This method always returns an immutable object.
-
add
public BlockPos add(Vec3i vec3i)
- 覆盖:
add在类中Vec3i- Mappings:
Namespace Name Mixin selector official aLgb;a(Lgw;)Lgb;intermediary method_10081Lnet/minecraft/class_2338;method_10081(Lnet/minecraft/class_2382;)Lnet/minecraft/class_2338;named addLnet/minecraft/util/math/BlockPos;add(Lnet/minecraft/util/math/Vec3i;)Lnet/minecraft/util/math/BlockPos;
-
subtract
public BlockPos subtract(Vec3i vec3i)
- 覆盖:
subtract在类中Vec3i- Mappings:
Namespace Name Mixin selector official bLgb;b(Lgw;)Lgb;intermediary method_10059Lnet/minecraft/class_2338;method_10059(Lnet/minecraft/class_2382;)Lnet/minecraft/class_2338;named subtractLnet/minecraft/util/math/BlockPos;subtract(Lnet/minecraft/util/math/Vec3i;)Lnet/minecraft/util/math/BlockPos;
-
multiply
public BlockPos multiply(int int2)
-
up
public BlockPos up()
-
up
public BlockPos up(int distance)
-
down
public BlockPos down()
-
down
public BlockPos down(int int2)
-
north
public BlockPos north()
-
north
public BlockPos north(int distance)
-
south
public BlockPos south()
-
south
public BlockPos south(int distance)
-
west
public BlockPos west()
-
west
public BlockPos west(int distance)
-
east
public BlockPos east()
-
east
public BlockPos east(int distance)
-
offset
public BlockPos offset(Direction direction)
- 覆盖:
offset在类中Vec3i- Mappings:
Namespace Name Mixin selector official aLgb;a(Lgg;)Lgb;intermediary method_10093Lnet/minecraft/class_2338;method_10093(Lnet/minecraft/class_2350;)Lnet/minecraft/class_2338;named offsetLnet/minecraft/util/math/BlockPos;offset(Lnet/minecraft/util/math/Direction;)Lnet/minecraft/util/math/BlockPos;
-
offset
public BlockPos offset(Direction direction, int int2)
- 覆盖:
offset在类中Vec3i- Mappings:
Namespace Name Mixin selector official aLgb;a(Lgg;I)Lgb;intermediary method_10079Lnet/minecraft/class_2338;method_10079(Lnet/minecraft/class_2350;I)Lnet/minecraft/class_2338;named offsetLnet/minecraft/util/math/BlockPos;offset(Lnet/minecraft/util/math/Direction;I)Lnet/minecraft/util/math/BlockPos;
-
offset
public BlockPos offset(Direction.Axis axis, int int2)
- 覆盖:
offset在类中Vec3i- Mappings:
Namespace Name Mixin selector official aLgb;a(Lgg$a;I)Lgb;intermediary method_30513Lnet/minecraft/class_2338;method_30513(Lnet/minecraft/class_2350$class_2351;I)Lnet/minecraft/class_2338;named offsetLnet/minecraft/util/math/BlockPos;offset(Lnet/minecraft/util/math/Direction$Axis;I)Lnet/minecraft/util/math/BlockPos;
-
rotate
public BlockPos rotate(BlockRotation rotation)
- Mappings:
Namespace Name Mixin selector official aLgb;a(Lcek;)Lgb;intermediary method_10070Lnet/minecraft/class_2338;method_10070(Lnet/minecraft/class_2470;)Lnet/minecraft/class_2338;named rotateLnet/minecraft/util/math/BlockPos;rotate(Lnet/minecraft/util/BlockRotation;)Lnet/minecraft/util/math/BlockPos;
-
crossProduct
public BlockPos crossProduct(Vec3i pos)
- 覆盖:
crossProduct在类中Vec3i- Mappings:
Namespace Name Mixin selector official cLgb;c(Lgw;)Lgb;intermediary method_10075Lnet/minecraft/class_2338;method_10075(Lnet/minecraft/class_2382;)Lnet/minecraft/class_2338;named crossProductLnet/minecraft/util/math/BlockPos;crossProduct(Lnet/minecraft/util/math/Vec3i;)Lnet/minecraft/util/math/BlockPos;
-
withY
public BlockPos withY(int y)
- Mappings:
Namespace Name Mixin selector official hLgb;h(I)Lgb;intermediary method_33096Lnet/minecraft/class_2338;method_33096(I)Lnet/minecraft/class_2338;named withYLnet/minecraft/util/math/BlockPos;withY(I)Lnet/minecraft/util/math/BlockPos;
-
toImmutable
public BlockPos toImmutable()
Returns an immutable block position with the same x, y, and z as this position.This method should be called when a block position is used as map keys as to prevent side effects of mutations of mutable block positions.
- Mappings:
Namespace Name Mixin selector official hLgb;h()Lgb;intermediary method_10062Lnet/minecraft/class_2338;method_10062()Lnet/minecraft/class_2338;named toImmutableLnet/minecraft/util/math/BlockPos;toImmutable()Lnet/minecraft/util/math/BlockPos;
-
mutableCopy
public BlockPos.Mutable mutableCopy()
Returns a mutable copy of this block position.If this block position is a mutable one, mutation to this block position won't affect the returned position.
- Mappings:
Namespace Name Mixin selector official iLgb;i()Lgb$a;intermediary method_25503Lnet/minecraft/class_2338;method_25503()Lnet/minecraft/class_2338$class_2339;named mutableCopyLnet/minecraft/util/math/BlockPos;mutableCopy()Lnet/minecraft/util/math/BlockPos$Mutable;
-
iterateRandomly
public static Iterable<BlockPos> iterateRandomly(Random random, int count, BlockPos around, int range)
Iterates throughcountrandom block positions in a given range around the given position.The iterator yields positions in no specific order. The same position may be returned multiple times by the iterator.
- 参数:
random- theRandomobject used to compute new positionscount- the number of positions to iteratearound- theBlockPosto iterate aroundrange- the maximum distance from the given pos in any axis- Mappings:
Namespace Name Mixin selector official aLgb;a(Ljava/util/Random;ILgb;I)Ljava/lang/Iterable;intermediary method_34848Lnet/minecraft/class_2338;method_34848(Ljava/util/Random;ILnet/minecraft/class_2338;I)Ljava/lang/Iterable;named iterateRandomlyLnet/minecraft/util/math/BlockPos;iterateRandomly(Ljava/util/Random;ILnet/minecraft/util/math/BlockPos;I)Ljava/lang/Iterable;
-
iterateRandomly
public static Iterable<BlockPos> iterateRandomly(Random random, int count, int minX, int minY, int minZ, int maxX, int maxY, int maxZ)
Iterates throughcountrandom block positions in the given area.The iterator yields positions in no specific order. The same position may be returned multiple times by the iterator.
- 参数:
random- theRandomobject used to compute new positionscount- the number of positions to iterateminX- the minimum x value for returned positionsminY- the minimum y value for returned positionsminZ- the minimum z value for returned positionsmaxX- the maximum x value for returned positionsmaxY- the maximum y value for returned positionsmaxZ- the maximum z value for returned positions- Mappings:
Namespace Name Mixin selector official aLgb;a(Ljava/util/Random;IIIIIII)Ljava/lang/Iterable;intermediary method_27156Lnet/minecraft/class_2338;method_27156(Ljava/util/Random;IIIIIII)Ljava/lang/Iterable;named iterateRandomlyLnet/minecraft/util/math/BlockPos;iterateRandomly(Ljava/util/Random;IIIIIII)Ljava/lang/Iterable;
-
iterateOutwards
public static Iterable<BlockPos> iterateOutwards(BlockPos center, int xRange, int yRange, int zRange)
Iterates block positions around thecenter. The iteration order is mainly based on the manhattan distance of the position from the center.For the same manhattan distance, the positions are iterated by y offset, from negative to positive. For the same y offset, the positions are iterated by x offset, from negative to positive. For the two positions with the same x and y offsets and the same manhattan distance, the one with a positive z offset is visited first before the one with a negative z offset.
- 参数:
center- the center of iterationxRange- the maximum x difference from the centeryRange- the maximum y difference from the centerzRange- the maximum z difference from the center- Mappings:
Namespace Name Mixin selector official aLgb;a(Lgb;III)Ljava/lang/Iterable;intermediary method_25996Lnet/minecraft/class_2338;method_25996(Lnet/minecraft/class_2338;III)Ljava/lang/Iterable;named iterateOutwardsLnet/minecraft/util/math/BlockPos;iterateOutwards(Lnet/minecraft/util/math/BlockPos;III)Ljava/lang/Iterable;
-
findClosest
public static Optional<BlockPos> findClosest(BlockPos pos, int horizontalRange, int verticalRange, Predicate<BlockPos> condition)
- Mappings:
Namespace Name Mixin selector official aLgb;a(Lgb;IILjava/util/function/Predicate;)Ljava/util/Optional;intermediary method_25997Lnet/minecraft/class_2338;method_25997(Lnet/minecraft/class_2338;IILjava/util/function/Predicate;)Ljava/util/Optional;named findClosestLnet/minecraft/util/math/BlockPos;findClosest(Lnet/minecraft/util/math/BlockPos;IILjava/util/function/Predicate;)Ljava/util/Optional;
-
streamOutwards
public static Stream<BlockPos> streamOutwards(BlockPos center, int maxX, int maxY, int maxZ)
- Mappings:
Namespace Name Mixin selector official bLgb;b(Lgb;III)Ljava/util/stream/Stream;intermediary method_25998Lnet/minecraft/class_2338;method_25998(Lnet/minecraft/class_2338;III)Ljava/util/stream/Stream;named streamOutwardsLnet/minecraft/util/math/BlockPos;streamOutwards(Lnet/minecraft/util/math/BlockPos;III)Ljava/util/stream/Stream;
-
iterate
public static Iterable<BlockPos> iterate(BlockPos start, BlockPos end)
- Mappings:
Namespace Name Mixin selector official aLgb;a(Lgb;Lgb;)Ljava/lang/Iterable;intermediary method_10097Lnet/minecraft/class_2338;method_10097(Lnet/minecraft/class_2338;Lnet/minecraft/class_2338;)Ljava/lang/Iterable;named iterateLnet/minecraft/util/math/BlockPos;iterate(Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/util/math/BlockPos;)Ljava/lang/Iterable;
-
stream
public static Stream<BlockPos> stream(BlockPos start, BlockPos end)
- Mappings:
Namespace Name Mixin selector official bLgb;b(Lgb;Lgb;)Ljava/util/stream/Stream;intermediary method_20437Lnet/minecraft/class_2338;method_20437(Lnet/minecraft/class_2338;Lnet/minecraft/class_2338;)Ljava/util/stream/Stream;named streamLnet/minecraft/util/math/BlockPos;stream(Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/util/math/BlockPos;)Ljava/util/stream/Stream;
-
stream
public static Stream<BlockPos> stream(BlockBox box)
- Mappings:
Namespace Name Mixin selector official aLgb;a(Lczr;)Ljava/util/stream/Stream;intermediary method_23627Lnet/minecraft/class_2338;method_23627(Lnet/minecraft/class_3341;)Ljava/util/stream/Stream;named streamLnet/minecraft/util/math/BlockPos;stream(Lnet/minecraft/util/math/BlockBox;)Ljava/util/stream/Stream;
-
stream
public static Stream<BlockPos> stream(Box box)
- Mappings:
Namespace Name Mixin selector official aLgb;a(Ldlv;)Ljava/util/stream/Stream;intermediary method_29715Lnet/minecraft/class_2338;method_29715(Lnet/minecraft/class_238;)Ljava/util/stream/Stream;named streamLnet/minecraft/util/math/BlockPos;stream(Lnet/minecraft/util/math/Box;)Ljava/util/stream/Stream;
-
stream
public static Stream<BlockPos> stream(int startX, int startY, int startZ, int endX, int endY, int endZ)
- Mappings:
Namespace Name Mixin selector official aLgb;a(IIIIII)Ljava/util/stream/Stream;intermediary method_17962Lnet/minecraft/class_2338;method_17962(IIIIII)Ljava/util/stream/Stream;named streamLnet/minecraft/util/math/BlockPos;stream(IIIIII)Ljava/util/stream/Stream;
-
iterate
public static Iterable<BlockPos> iterate(int startX, int startY, int startZ, int endX, int endY, int endZ)
- Mappings:
Namespace Name Mixin selector official bLgb;b(IIIIII)Ljava/lang/Iterable;intermediary method_10094Lnet/minecraft/class_2338;method_10094(IIIIII)Ljava/lang/Iterable;named iterateLnet/minecraft/util/math/BlockPos;iterate(IIIIII)Ljava/lang/Iterable;
-
iterateInSquare
public static Iterable<BlockPos.Mutable> iterateInSquare(BlockPos center, int radius, Direction firstDirection, Direction secondDirection)
Iterates block positions around thecenterin a square of (2 * radius + 1) by (2 * radius + 1). The blocks are iterated in a (square) spiral around the center.The first block returned is the center, then the iterator moves a block towards the first direction, followed by moving along the second direction.
- 参数:
center- the center of iterationradius- the maximum chebychev distancefirstDirection- the direction the iterator moves firstsecondDirection- the direction the iterator moves after the first- 抛出:
IllegalStateException- when the 2 directions lie on the same axis- Mappings:
Namespace Name Mixin selector official aLgb;a(Lgb;ILgg;Lgg;)Ljava/lang/Iterable;intermediary method_30512Lnet/minecraft/class_2338;method_30512(Lnet/minecraft/class_2338;ILnet/minecraft/class_2350;Lnet/minecraft/class_2350;)Ljava/lang/Iterable;named iterateInSquareLnet/minecraft/util/math/BlockPos;iterateInSquare(Lnet/minecraft/util/math/BlockPos;ILnet/minecraft/util/math/Direction;Lnet/minecraft/util/math/Direction;)Ljava/lang/Iterable;
-
-