mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 11:39:43 +00:00
player doesnt fall when he is on the world border, player is not spawning on world border if he logged in nearby it
This commit is contained in:
parent
431063ad83
commit
4ffa7f46a4
2 changed files with 4 additions and 2 deletions
|
|
@ -1425,8 +1425,7 @@ class Player{
|
|||
$pk = new SetTimePacket;
|
||||
$pk->time = $this->level->getTime();
|
||||
$this->dataPacket($pk);
|
||||
|
||||
$pos = new Position($this->data->get("position")["x"], $this->data->get("position")["y"], $this->data->get("position")["z"], $this->level);
|
||||
$pos = new Position(floor($this->data->get("position")["x"]), floor($this->data->get("position")["y"]), floor($this->data->get("position")["z"]), $this->level);
|
||||
$pos = $this->level->getSafeSpawn($pos);
|
||||
$this->teleport($pos);
|
||||
$this->server->schedule(10, [$this, "teleport"], $pos);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue