GenisysPro  for Minecraft PE/Windows 10 v1.1.x
Feature-rich server software for Minecraft PE and Windows 10 Edition
SetTitlePacket Class Reference

Public Member Functions

 decode ()
 
 encode ()
 
 getName ()
 
- Public Member Functions inherited from DataPacket
 pid ()
 
 encode ()
 
 decode ()
 
 reset ()
 
 clean ()
 
 __debugInfo ()
 
 getEntityMetadata (bool $types=true)
 
 putEntityMetadata (array $metadata)
 
 getName ()
 
- Public Member Functions inherited from BinaryStream
 __construct ($buffer="", $offset=0)
 
 reset ()
 
 setBuffer ($buffer=null, $offset=0)
 
 getOffset ()
 
 getBuffer ()
 
 get ($len)
 
 put ($str)
 
 getBool ()
 
 putBool ($v)
 
 getLong ()
 
 putLong ($v)
 
 getInt ()
 
 putInt ($v)
 
 getLLong ()
 
 putLLong ($v)
 
 getLInt ()
 
 putLInt ($v)
 
 getSignedShort ()
 
 putShort ($v)
 
 getShort ()
 
 putSignedShort ($v)
 
 getFloat (int $accuracy=-1)
 
 putFloat ($v)
 
 getLShort ($signed=true)
 
 putLShort ($v)
 
 getLFloat (int $accuracy=-1)
 
 putLFloat ($v)
 
 getTriad ()
 
 putTriad ($v)
 
 getLTriad ()
 
 putLTriad ($v)
 
 getByte ()
 
 putByte ($v)
 
 getUUID ()
 
 putUUID (UUID $uuid)
 
 getSlot ()
 
 putSlot (Item $item)
 
 getString ()
 
 putString ($v)
 
 getUnsignedVarInt ()
 
 putUnsignedVarInt ($v)
 
 getVarInt ()
 
 putVarInt ($v)
 
 getEntityId ()
 
 putEntityId ($v)
 
 getBlockCoords (&$x, &$y, &$z)
 
 putBlockCoords ($x, $y, $z)
 
 getVector3f (&$x, &$y, &$z)
 
 putVector3f ($x, $y, $z)
 
 feof ()
 

Data Fields

const NETWORK_ID = ProtocolInfo::SET_TITLE_PACKET
 
const TYPE_CLEAR = 0
 
const TYPE_RESET = 1
 
const TYPE_TITLE = 2
 
const TYPE_SUB_TITLE = 3
 
const TYPE_ACTION_BAR = 4
 
const TYPE_TIMES = 5
 
 $type
 
 $title
 
 $fadeInDuration
 
 $duration
 
 $fadeOutDuration
 
- Data Fields inherited from DataPacket
const NETWORK_ID = 0
 
 $isEncoded = false
 
- Data Fields inherited from BinaryStream
 $offset
 
 $buffer
 

Member Function Documentation

◆ decode()

decode ( )
46  {
47  $this->type = $this->getVarInt();
48  $this->title = $this->getString();
49  $this->fadeInDuration = $this->getVarInt();
50  $this->duration = $this->getVarInt();
51  $this->fadeOutDuration = $this->getVarInt();
52  }

◆ encode()

encode ( )
57  {
58  $this->reset();
59  $this->putVarInt($this->type);
60  $this->putString($this->title);
61  $this->putVarInt($this->fadeInDuration);
62  $this->putVarInt($this->duration);
63  $this->putVarInt($this->fadeOutDuration);
64  }

◆ getName()

getName ( )
Returns
PacketName|string
69  {
70  return "SetTitlePacket";
71  }

Field Documentation

◆ $duration

$duration

◆ $fadeInDuration

$fadeInDuration

◆ $fadeOutDuration

$fadeOutDuration

◆ $title

$title

◆ $type

$type

◆ NETWORK_ID

const NETWORK_ID = ProtocolInfo::SET_TITLE_PACKET

◆ TYPE_ACTION_BAR

const TYPE_ACTION_BAR = 4

◆ TYPE_CLEAR

const TYPE_CLEAR = 0

◆ TYPE_RESET

const TYPE_RESET = 1

◆ TYPE_SUB_TITLE

const TYPE_SUB_TITLE = 3

◆ TYPE_TIMES

const TYPE_TIMES = 5

◆ TYPE_TITLE

const TYPE_TITLE = 2

The documentation for this class was generated from the following file: