mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 11:39:43 +00:00
always get level spawn when respawning instead of using spawnposition
This commit is contained in:
parent
d735564948
commit
f7fb798c0f
1 changed files with 1 additions and 2 deletions
|
|
@ -2424,7 +2424,7 @@ class Player{
|
|||
$this->craftingType = CraftingRecipes::TYPE_INVENTORY;
|
||||
|
||||
$this->checkSpawnPosition();
|
||||
$tpTarget = $this->spawnPosition;
|
||||
$tpTarget = $this->level->getSpawn();
|
||||
if($this->bedPosition != null){
|
||||
[$levelname, $x, $y, $z] = $this->bedPosition;
|
||||
$level = $this->server->api->level->get($levelname);
|
||||
|
|
@ -2432,7 +2432,6 @@ class Player{
|
|||
remove_bed:
|
||||
$this->sendChat("The bed is missing or cannot be accessed.");
|
||||
$this->setBedPosition(null);
|
||||
$this->setSpawn($this->level->getSpawn());
|
||||
}else{
|
||||
$spawnPoint = BedBlock::findStandUpPosition($level, $x, $y, $z);
|
||||
if($spawnPoint == null) goto remove_bed;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue