Update packetid name

This commit is contained in:
Tnze
2021-12-09 20:24:39 +08:00
parent 805ca37a67
commit 0cc5695aa3
15 changed files with 203 additions and 474 deletions

View File

@ -73,7 +73,7 @@ func (p *Player) handleJoinGamePacket(packet pk.Packet) error {
p.WorldNames = *(*[]string)(unsafe.Pointer(&WorldNames))
err = p.c.Conn.WritePacket(pk.Marshal( //PluginMessage packet
packetid.CustomPayloadServerbound,
packetid.ServerboundCustomPayload,
pk.Identifier("minecraft:brand"),
pk.String(p.Settings.Brand),
))
@ -82,7 +82,7 @@ func (p *Player) handleJoinGamePacket(packet pk.Packet) error {
}
err = p.c.Conn.WritePacket(pk.Marshal(
packetid.Settings, // Client settings
packetid.ServerboundClientInformation, // Client settings
pk.String(p.Settings.Locale),
pk.Byte(p.Settings.ViewDistance),
pk.VarInt(p.Settings.ChatMode),