mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-10-16 19:59:11 +00:00
Fixed invalid Position object on teleport
This commit is contained in:
@@ -887,7 +887,7 @@ class Player{
|
||||
return false;
|
||||
}
|
||||
|
||||
if($pos instanceof Position and $pos->level !== $this->level){
|
||||
if($pos instanceof Position and $pos->level instanceof Level and $pos->level !== $this->level){
|
||||
if($this->server->api->dhandle("player.teleport.level", array("player" => $this, "origin" => $this->level, "target" => $pos->level)) === false){
|
||||
$this->entity->check = true;
|
||||
return false;
|
||||
|
Reference in New Issue
Block a user