Update Player.php

This commit is contained in:
PEMapModder 2015-10-31 21:18:06 +08:00
parent 04fc062b2a
commit ea8ba995ac

View File

@ -1856,7 +1856,7 @@ class Player extends Human implements CommandSender, InventoryHolder, ChunkLoade
}
if($this->teleportPosition !== null or ($this->forceMovement instanceof Vector3 and (($dist = $newPos->distanceSquared($this->forceMovement)) > 0.1 or $revert))){
$this->sendPosition($this->forceMovement, $packet->yaw, $packet->pitch);
$this->sendPosition($this->teleportPosition === null ? $this->forceMovement : $this->teleportPosition, $packet->yaw, $packet->pitch);
}else{
$packet->yaw %= 360;
$packet->pitch %= 360;