Fixed improper pre-checking of PlayerAuthInputPacket flags

This commit is contained in:
Dylan K. Taylor 2025-05-28 23:29:37 +01:00
parent b40b99fe72
commit 0910a219d4
No known key found for this signature in database
GPG Key ID: 8927471A91CAFD3D
3 changed files with 9 additions and 9 deletions

View File

@ -36,7 +36,7 @@
"pocketmine/bedrock-block-upgrade-schema": "~5.1.0+bedrock-1.21.60",
"pocketmine/bedrock-data": "~5.0.0+bedrock-1.21.80",
"pocketmine/bedrock-item-upgrade-schema": "~1.14.0+bedrock-1.21.50",
"pocketmine/bedrock-protocol": "~38.0.0+bedrock-1.21.80",
"pocketmine/bedrock-protocol": "~38.1.0+bedrock-1.21.80",
"pocketmine/binaryutils": "^0.2.1",
"pocketmine/callback-validator": "^1.0.2",
"pocketmine/color": "^0.3.0",

14
composer.lock generated
View File

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
"content-hash": "ceb98091ac3f61f1a4b87708c48dc75a",
"content-hash": "fe62caebfdb35cd8bd57c8e61879b7c0",
"packages": [
{
"name": "adhocore/json-comment",
@ -256,16 +256,16 @@
},
{
"name": "pocketmine/bedrock-protocol",
"version": "38.0.1+bedrock-1.21.80",
"version": "38.1.0+bedrock-1.21.80",
"source": {
"type": "git",
"url": "https://github.com/pmmp/BedrockProtocol.git",
"reference": "0c1c13e970a2e1ded1609d0b442b4fcfd24cd21f"
"reference": "a1fa215563517050045309bb779a67f75843b867"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/pmmp/BedrockProtocol/zipball/0c1c13e970a2e1ded1609d0b442b4fcfd24cd21f",
"reference": "0c1c13e970a2e1ded1609d0b442b4fcfd24cd21f",
"url": "https://api.github.com/repos/pmmp/BedrockProtocol/zipball/a1fa215563517050045309bb779a67f75843b867",
"reference": "a1fa215563517050045309bb779a67f75843b867",
"shasum": ""
},
"require": {
@ -296,9 +296,9 @@
"description": "An implementation of the Minecraft: Bedrock Edition protocol in PHP",
"support": {
"issues": "https://github.com/pmmp/BedrockProtocol/issues",
"source": "https://github.com/pmmp/BedrockProtocol/tree/38.0.1+bedrock-1.21.80"
"source": "https://github.com/pmmp/BedrockProtocol/tree/38.1.0+bedrock-1.21.80"
},
"time": "2025-05-17T11:56:33+00:00"
"time": "2025-05-28T22:19:59+00:00"
},
{
"name": "pocketmine/binaryutils",

View File

@ -211,7 +211,7 @@ class InGamePacketHandler extends PacketHandler{
}
$inputFlags = $packet->getInputFlags();
if($inputFlags !== $this->lastPlayerAuthInputFlags){
if($this->lastPlayerAuthInputFlags === null || !$inputFlags->equals($this->lastPlayerAuthInputFlags)){
$this->lastPlayerAuthInputFlags = $inputFlags;
$sneaking = $inputFlags->get(PlayerAuthInputFlags::SNEAKING);