mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-03 08:35:20 +00:00
Fix player list duplicates
This commit is contained in:
@ -2219,6 +2219,9 @@ class Server{
|
||||
$pk = new PlayerListPacket();
|
||||
$pk->type = PlayerListPacket::TYPE_ADD;
|
||||
foreach($this->playerList as $player){
|
||||
if($p === $player){
|
||||
continue; //fixes duplicates
|
||||
}
|
||||
$pk->entries[] = [$player->getUniqueId(), $player->getId(), $player->getDisplayName(), $player->getSkinId(), $player->getSkinData()];
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user