mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-05-13 01:09:44 +00:00
Send extra id on Add/Remove player
This commit is contained in:
parent
f71cf1c749
commit
6b1b6711bd
@ -1229,9 +1229,9 @@ abstract class Entity extends Location implements Metadatable{
|
||||
$minX = Math::floorFloat($this->boundingBox->minX + 0.001);
|
||||
$minY = Math::floorFloat($this->boundingBox->minY + 0.001);
|
||||
$minZ = Math::floorFloat($this->boundingBox->minZ + 0.001);
|
||||
$maxX = Math::floorFloat($this->boundingBox->maxX - 0.001);
|
||||
$maxY = Math::floorFloat($this->boundingBox->maxY - 0.001);
|
||||
$maxZ = Math::floorFloat($this->boundingBox->maxZ - 0.001);
|
||||
$maxX = Math::ceilFloat($this->boundingBox->maxX - 0.001);
|
||||
$maxY = Math::ceilFloat($this->boundingBox->maxY - 0.001);
|
||||
$maxZ = Math::ceilFloat($this->boundingBox->maxZ - 0.001);
|
||||
|
||||
$vector = new Vector3(0, 0, 0);
|
||||
$v = new Vector3(0, 0, 0);
|
||||
|
@ -198,7 +198,7 @@ class Human extends Creature implements ProjectileSource, InventoryHolder{
|
||||
}
|
||||
|
||||
$pk = new AddPlayerPacket();
|
||||
$pk->clientID = 0;
|
||||
$pk->clientID = $this->getId();
|
||||
$pk->username = $this->nameTag;
|
||||
$pk->eid = $this->getId();
|
||||
$pk->x = $this->x;
|
||||
@ -224,7 +224,7 @@ class Human extends Creature implements ProjectileSource, InventoryHolder{
|
||||
if(isset($this->hasSpawned[$player->getId()])){
|
||||
$pk = new RemovePlayerPacket();
|
||||
$pk->eid = $this->id;
|
||||
$pk->clientID = 0;
|
||||
$pk->clientID = $this->id;
|
||||
$player->dataPacket($pk);
|
||||
unset($this->hasSpawned[$player->getId()]);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user