Added extra Exceptions

This commit is contained in:
Shoghi Cervantes
2014-10-28 21:07:12 +01:00
parent b6f7ee20fc
commit 8c4faa8622
37 changed files with 215 additions and 87 deletions

View File

@ -32,6 +32,7 @@ use pocketmine\level\Level;
use pocketmine\level\Position;
use pocketmine\nbt\tag\Compound;
use pocketmine\nbt\tag\Int;
use pocketmine\utils\ChunkException;
abstract class Tile extends Position{
const SIGN = "Sign";
@ -95,7 +96,7 @@ abstract class Tile extends Position{
public function __construct(FullChunk $chunk, Compound $nbt){
if($chunk === null or $chunk->getProvider() === null){
throw new \Exception("Invalid garbage Chunk given to Tile");
throw new ChunkException("Invalid garbage Chunk given to Tile");
}
$this->timings = Timings::getTileEntityTimings($this);