From 7bbda6dd6749493e92968865effb028ccb1ab6a2 Mon Sep 17 00:00:00 2001 From: Shoghi Cervantes Pueyo Date: Thu, 16 May 2013 20:24:05 +0200 Subject: [PATCH] Detect non loaded chunks --- src/pmf/Level.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pmf/Level.php b/src/pmf/Level.php index e240468bdd..c1daf68e0b 100644 --- a/src/pmf/Level.php +++ b/src/pmf/Level.php @@ -292,7 +292,7 @@ class PMFLevel extends PMF{ return array(AIR, 0); } $index = $this->getIndex($X, $Z); - if($this->chunks[$index] === false){ + if(!isset($this->chunks[$index]) or $this->chunks[$index] === false){ if($this->loadChunk($X, $Z) === false){ return array(AIR, 0); } @@ -324,7 +324,7 @@ class PMFLevel extends PMF{ return false; } $index = $this->getIndex($X, $Z); - if($this->chunks[$index] === false){ + if(!isset($this->chunks[$index]) or $this->chunks[$index] === false){ if($this->loadChunk($X, $Z) === false){ return false; }