public class BlockUtils extends Object
| Modifier and Type | Field and Description |
|---|---|
static com.github.steveice10.mc.protocol.data.game.entity.metadata.Position |
POSITION_ZERO
A static constant of
Position with all values being zero. |
| Constructor and Description |
|---|
BlockUtils() |
| Modifier and Type | Method and Description |
|---|---|
static com.nukkitx.math.vector.Vector3i |
getBlockPosition(com.nukkitx.math.vector.Vector3i blockPos,
int face)
Given a position, return the position if a block were located on the specified block face.
|
static double |
getBreakTime(GeyserSession session,
BlockMapping blockMapping,
ItemMapping item,
com.github.steveice10.opennbt.tag.builtin.CompoundTag nbtData,
boolean isSessionPlayer) |
static BlockCollision |
getCollision(int blockId,
int x,
int y,
int z) |
static BlockCollision |
getCollisionAt(GeyserSession session,
int x,
int y,
int z) |
static double |
getSessionBreakTime(GeyserSession session,
BlockMapping blockMapping) |
public static final com.github.steveice10.mc.protocol.data.game.entity.metadata.Position POSITION_ZERO
Position with all values being zero.public static double getBreakTime(GeyserSession session, BlockMapping blockMapping, ItemMapping item, com.github.steveice10.opennbt.tag.builtin.CompoundTag nbtData, boolean isSessionPlayer)
public static double getSessionBreakTime(GeyserSession session, BlockMapping blockMapping)
public static com.nukkitx.math.vector.Vector3i getBlockPosition(com.nukkitx.math.vector.Vector3i blockPos,
int face)
blockPos - the block positionface - the face of the block - see BlockFacepublic static BlockCollision getCollision(int blockId, int x, int y, int z)
public static BlockCollision getCollisionAt(GeyserSession session, int x, int y, int z)
Copyright © 2021 GeyserMC. All rights reserved.