From db5ff450054cacbe3484e9cfdf889836434a017f Mon Sep 17 00:00:00 2001 From: AkmalFairuz Date: Sun, 22 Sep 2024 21:35:01 +0700 Subject: [PATCH] fix wrong emote packet --- src/EmotePacket.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/EmotePacket.php b/src/EmotePacket.php index 6d71b406..1545ae52 100644 --- a/src/EmotePacket.php +++ b/src/EmotePacket.php @@ -67,7 +67,7 @@ protected function decodePayload(PacketSerializer $in) : void{ $this->actorRuntimeId = $in->getActorRuntimeId(); $this->emoteId = $in->getString(); if($in->getProtocol() >= ProtocolInfo::PROTOCOL_729){ - $this->emoteLengthTicks = $in->getInt(); + $this->emoteLengthTicks = $in->getUnsignedVarInt(); } if($in->getProtocol() >= ProtocolInfo::PROTOCOL_589){ $this->xboxUserId = $in->getString(); @@ -83,7 +83,7 @@ protected function encodePayload(PacketSerializer $out) : void{ $out->putActorRuntimeId($this->actorRuntimeId); $out->putString($this->emoteId); if($out->getProtocol() >= ProtocolInfo::PROTOCOL_729){ - $out->putInt($this->emoteLengthTicks); + $out->putUnsignedVarInt($this->emoteLengthTicks); } if($out->getProtocol() >= ProtocolInfo::PROTOCOL_589){ $out->putString($this->xboxUserId);