C07PacketPlayerDigging
Last updated
Packet sent when breaking blocks or dropping items
const packet = new C07PacketPlayerDigging('START_DESTROY_BLOCK', blockPos, 'UP');new C07PacketPlayerDigging(
action,block,face):C07PacketPlayerDigging
Create a new C07PacketPlayerDigging packet
Parameters
action
The dig action (START_DESTROY_BLOCK, ABORT_DESTROY_BLOCK, STOP_DESTROY_BLOCK, DROP_ALL_ITEMS, DROP_ITEM, RELEASE_USE_ITEM)
block
The block position
face
The block face (DOWN, UP, NORTH, SOUTH, WEST, EAST)
Returns
C07PacketPlayerDigging
Overrides
Packet.constructor
getAction():
DiggingAction
Get the dig action
Returns
The dig action name
getFace():
EnumFacing
Get the block face
Returns
The block face name
getPacketID():
string
Get the ID of the packet.
Returns
string
The ID of the packet.
Inherited from
getPosition():
BlockPos
Get the block position
Returns
The block position
setAction(
action):void
Set the dig action
Parameters
action
The dig action name
Returns
void
setFace(
face):void
Set the block face
Parameters
face
The block face name
Returns
void
setPosition(
pos):void
Set the block position
Parameters
pos
The new block position
Returns
void
Last updated