PocketMine-MP  1.4 - API 1.10.0
 All Classes Namespaces Functions Variables Pages
FullChunk.php
1 <?php
2 
3 /*
4  *
5  * ____ _ _ __ __ _ __ __ ____
6  * | _ \ ___ ___| | _____| |_| \/ (_)_ __ ___ | \/ | _ \
7  * | |_) / _ \ / __| |/ / _ \ __| |\/| | | '_ \ / _ \_____| |\/| | |_) |
8  * | __/ (_) | (__| < __/ |_| | | | | | | | __/_____| | | | __/
9  * |_| \___/ \___|_|\_\___|\__|_| |_|_|_| |_|\___| |_| |_|_|
10  *
11  * This program is free software: you can redistribute it and/or modify
12  * it under the terms of the GNU Lesser General Public License as published by
13  * the Free Software Foundation, either version 3 of the License, or
14  * (at your option) any later version.
15  *
16  * @author PocketMine Team
17  * @link http://www.pocketmine.net/
18  *
19  *
20 */
21 
22 namespace pocketmine\level\format;
23 
26 
27 interface FullChunk{
28 
32  public function getX();
33 
37  public function getZ();
38 
39  public function setX($x);
40 
41  public function setZ($z);
42 
46  public function getProvider();
47 
51  public function setProvider(LevelProvider $provider);
52 
53 
65  public function getBlock($x, $y, $z, &$blockId, &$meta = null);
66 
76  public function getFullBlock($x, $y, $z);
77 
86  public function setBlock($x, $y, $z, $blockId = null, $meta = null);
87 
95  public function getBlockId($x, $y, $z);
96 
103  public function setBlockId($x, $y, $z, $id);
104 
112  public function getBlockData($x, $y, $z);
113 
120  public function setBlockData($x, $y, $z, $data);
121 
129  public function getBlockSkyLight($x, $y, $z);
130 
137  public function setBlockSkyLight($x, $y, $z, $level);
138 
146  public function getBlockLight($x, $y, $z);
147 
154  public function setBlockLight($x, $y, $z, $level);
155 
162  public function getHighestBlockAt($x, $z);
163 
170  public function getHeightMap($x, $z);
171 
177  public function setHeightMap($x, $z, $value);
178 
185  public function getBiomeId($x, $z);
186 
192  public function setBiomeId($x, $z, $biomeId);
193 
200  public function getBiomeColor($x, $z);
201 
202  public function getBlockIdColumn($x, $z);
203 
204  public function getBlockDataColumn($x, $z);
205 
206  public function getBlockSkyLightColumn($x, $z);
207 
208  public function getBlockLightColumn($x, $z);
209 
217  public function setBiomeColor($x, $z, $R, $G, $B);
218 
219  public function isPopulated();
220 
221  public function setPopulated($value = 1);
222 
223  public function isGenerated();
224 
225  public function setGenerated($value = 1);
226 
230  public function addEntity(Entity $entity);
231 
235  public function removeEntity(Entity $entity);
236 
240  public function addTile(Tile $tile);
241 
245  public function removeTile(Tile $tile);
246 
250  public function getEntities();
251 
255  public function getTiles();
256 
262  public function getTile($x, $y, $z);
263 
267  public function isLoaded();
268 
276  public function load($generate = true);
277 
284  public function unload($save = true, $safe = true);
285 
286  public function initChunk();
287 
291  public function getBiomeIdArray();
292 
296  public function getBiomeColorArray();
297 
301  public function getHeightMapArray();
302 
303  public function getBlockIdArray();
304 
305  public function getBlockDataArray();
306 
307  public function getBlockSkyLightArray();
308 
309  public function getBlockLightArray();
310 
311  public function toBinary();
312 
316  public function hasChanged();
317 
321  public function setChanged($changed = true);
322 
329  public static function fromBinary($data, LevelProvider $provider = null);
330 
331 }
setBlock($x, $y, $z, $blockId=null, $meta=null)
getBlock($x, $y, $z, &$blockId, &$meta=null)
setBlockSkyLight($x, $y, $z, $level)
unload($save=true, $safe=true)
setBlockLight($x, $y, $z, $level)
setBiomeColor($x, $z, $R, $G, $B)
setProvider(LevelProvider $provider)
setBlockData($x, $y, $z, $data)
static fromBinary($data, LevelProvider $provider=null)