Merge pull request #3956 from redcrab2016/redcrab2016-patch-1

PR: Bug Fix - Crash if player is spawn to Y coord. >0 & <1
This commit is contained in:
PEMapModder 2016-02-22 14:15:11 +08:00
commit 36028679d8

View File

@ -2601,7 +2601,7 @@ class Level implements ChunkManager, Metadatable{
* @return bool|Position
*/
public function getSafeSpawn($spawn = null){
if(!($spawn instanceof Vector3) or $spawn->y <= 0){
if(!($spawn instanceof Vector3) or $spawn->y < 1){
$spawn = $this->getSpawnLocation();
}
if($spawn instanceof Vector3){