ReleaseItemTransactionData
extends TransactionData
in package
Uses
GetTypeIdFromConstTrait
Table of Contents
- ACTION_CONSUME = 1
- ACTION_RELEASE = 0
- ID = \pocketmine\network\mcpe\protocol\InventoryTransactionPacket::TYPE_RELEASE_ITEM
- $actions : array<string|int, mixed>
- $actionType : int
- $headPosition : Vector3
- $hotbarSlot : int
- $itemInHand : ItemStackWrapper
- decode() : void
- encode() : void
- getActions() : array<string|int, NetworkInventoryAction>
- getActionType() : int
- getHeadPosition() : Vector3
- getHotbarSlot() : int
- getItemInHand() : ItemStackWrapper
- getTypeId() : int
- new() : self
- decodeData() : void
- encodeData() : void
Constants
ACTION_CONSUME
public
mixed
ACTION_CONSUME
= 1
ACTION_RELEASE
public
mixed
ACTION_RELEASE
= 0
ID
public
mixed
ID
= \pocketmine\network\mcpe\protocol\InventoryTransactionPacket::TYPE_RELEASE_ITEM
Properties
$actions
protected
array<string|int, mixed>
$actions
= []
$actionType
private
int
$actionType
$headPosition
private
Vector3
$headPosition
$hotbarSlot
private
int
$hotbarSlot
$itemInHand
private
ItemStackWrapper
$itemInHand
Methods
decode()
public
final decode(PacketSerializer $stream) : void
Parameters
- $stream : PacketSerializer
Tags
Return values
void —encode()
public
final encode(PacketSerializer $stream) : void
Parameters
- $stream : PacketSerializer
Return values
void —getActions()
public
final getActions() : array<string|int, NetworkInventoryAction>
Return values
array<string|int, NetworkInventoryAction> —getActionType()
public
getActionType() : int
Return values
int —getHeadPosition()
public
getHeadPosition() : Vector3
Return values
Vector3 —getHotbarSlot()
public
getHotbarSlot() : int
Return values
int —getItemInHand()
public
getItemInHand() : ItemStackWrapper
Return values
ItemStackWrapper —getTypeId()
public
abstract getTypeId() : int
Return values
int —new()
public
static new(array<string|int, NetworkInventoryAction> $actions, int $actionType, int $hotbarSlot, ItemStackWrapper $itemInHand, Vector3 $headPosition) : self
Parameters
- $actions : array<string|int, NetworkInventoryAction>
- $actionType : int
- $hotbarSlot : int
- $itemInHand : ItemStackWrapper
- $headPosition : Vector3
Return values
self —decodeData()
protected
decodeData(PacketSerializer $stream) : void
Parameters
- $stream : PacketSerializer
Return values
void —encodeData()
protected
encodeData(PacketSerializer $stream) : void
Parameters
- $stream : PacketSerializer