readded limit to resendQueue, MovePlayerPacket will be sent after AddPlayerPacket to fix AddPlayerPacket bug

This commit is contained in:
GameHerobrine 2025-07-01 09:47:04 +03:00
parent 31ae786748
commit 00c03d8bf0
2 changed files with 19 additions and 11 deletions

View file

@ -1621,7 +1621,9 @@ class Player{
}
if(($resendCnt = count($this->resendQueue)) > 0){
$limit = 25;
foreach($this->resendQueue as $count => $data){
if(!--$limit) break;
unset($this->resendQueue[$count]);
$this->packetStats[1]++;
$this->lag[] = $time - $data->sendtime;