Send extra id on Add/Remove player

This commit is contained in:
Shoghi Cervantes 2015-04-11 18:00:25 +02:00
parent f71cf1c749
commit 6b1b6711bd
No known key found for this signature in database
GPG Key ID: 78464DB0A7837F89
2 changed files with 5 additions and 5 deletions

View File

@ -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);

View File

@ -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()]);
}