Rosegold::Clientbound::PlayerInfoUpdate
Inherits Rosegold::Packets::ProtocolMapping / Rosegold::Clientbound::Packet / Rosegold::Packet / Rosegold::Event / Reference / Object
Constants
ADD_PLAYER = 1_u8
Action flags (bitfield)
INITIALIZE_CHAT = 2_u8
PROTOCOL_PACKET_IDS = {772_u32 => 63_u32, 774_u32 => 68_u32, 775_u32 => 70_u32}
Store the protocol mappings as a constant
UPDATE_DISPLAY_NAME = 32_u8
UPDATE_GAMEMODE = 4_u8
UPDATE_HAT = 128_u8
UPDATE_LATENCY = 16_u8
UPDATE_LIST_PRIORITY = 64_u8
UPDATE_LISTED = 8_u8
Constructors
Class methods
add_player(uuid : UUID, name : String, gamemode : Int32 = 0, latency : Int32 = 0, properties : Array(PlayerEntry::Property) | Nil = nil)
Convenience method to create an "Add Player" packet
packet_id
Provide backward compatibility with existing packet_id class getter Use the first protocol's packet ID for registration compatibility
packet_id_for_protocol(protocol_version : UInt32) : UInt32
Get packet ID for specific protocol version (returns UInt32 for VarInt encoding in write methods)
read(packet)
Sourcesupports_protocol?(protocol_version : UInt32) : Bool
Helper method to check if a protocol is supported
Instance methods
actions
Sourceactions=(actions : UInt8)
Sourcecallback(client)
Sourceplayers
Sourceplayers=(players : Array(PlayerEntry))
Sourcewrite
Source