Improved fall damage while on jump boost, new protocol update, build 7, allow for live inventory resizing

This commit is contained in:
Shoghi Cervantes
2015-04-24 16:43:29 +02:00
parent ba635b8858
commit 7b699d9afd
8 changed files with 61 additions and 47 deletions

View File

@ -49,6 +49,11 @@ class PlayerInventory extends BaseInventory{
return parent::getSize() - 4; //Remove armor slots
}
public function setSize($size){
parent::setSize($size + 4);
$this->sendContents($this->getViewers());
}
public function getHotbarSlotIndex($index){
return ($index >= 0 and $index < $this->getHotbarSize()) ? $this->hotbar[$index] : -1;
}