Skip to content

WrapperPlayer.java has invalid packet order according to mc protocol #57

@3add

Description

@3add

The WrapperPlayer.java class (extending living entity and thus entity) has a packet order that doesn't align with the mc protocol. The protocol requires the WrapperPlayServerPlayerInfoUpdate packet to be sent before the WrapperPlayServerSpawnEntity packet. (this is correctly done in the viewer functionality since the entity see:

if (this instanceof WrapperPlayer) {
WrapperPlayer p = (WrapperPlayer) this;
sendPacket(uuid, p.tabListPacket());
}
sendPacket(uuid, createSpawnPacket());
sendPacket(uuid, entityMeta.createPacket());
sendPacket(uuid, createPassengerPacket());
if (this instanceof WrapperLivingEntity) {
WrapperLivingEntity wrapperLivingEntity = (WrapperLivingEntity) this;
wrapperLivingEntity.createSpawnPackets().forEach(packetWrapper -> sendPacket(uuid, packetWrapper));
}
)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions