ProtocolLib

3M Downloads

Packet encoding of packet ID 104 threw (skippable? false)

KillerCreeper112 opened this issue ยท 0 comments

commented
  • This issue is not solved in a development build

Describe the bug
When trying to add a potion effect to a player, they get kicked, with the following error: https://pastebin.com/7ZDVGgiG

To Reproduce
Steps to reproduce the behavior:
Use this code here:
"p" is a Player.
PacketContainer newPacket = ProtocolLibrary.getProtocolManager().createPacket(PacketType.Play.Server.ENTITY_EFFECT);
newPacket.getIntegers().write(0, p.getEntityId());
newPacket.getBytes().write(0, (byte) 4).write(1, (byte) 0);
newPacket.getIntegers().write(1, 1);
ProtocolLibrary.getProtocolManager().sendServerPacket(p, newPacket);

Expected behavior
A potion effect packet is sent to the player... without them being kicked.

Screenshots
If applicable, add screenshots to help explain your problem.

Version Info
https://pastebin.com/ptnaUrAr

Additional context
Add any other context about the problem here.