Added Inventory interfaces and types, updated long array() to []

This commit is contained in:
Shoghi Cervantes
2014-05-22 18:59:16 +02:00
parent 0be679c9d5
commit 6cbd39de9b
102 changed files with 637 additions and 334 deletions

View File

@@ -53,17 +53,17 @@ abstract class Entity extends Position implements Metadatable{
/**
* @var Entity[]
*/
public static $list = array();
public static $list = [];
/**
* @var Entity[]
*/
public static $needUpdate = array();
public static $needUpdate = [];
/**
* @var Player[]
*/
protected $hasSpawned = array();
protected $hasSpawned = [];
protected $id;
@@ -424,7 +424,7 @@ abstract class Entity extends Position implements Metadatable{
$this->setLevel($targetLevel, true); //Hard reference
$this->getLevel()->entities[$this->id] = $this; //Oops, TODO!!
if($this instanceof Player){
$this->chunksLoaded = array();
$this->chunksLoaded = [];
$pk = new SetTimePacket();
$pk->time = $this->getLevel()->getTime();
$pk->started = $this->getLevel()->stopTime == false;