35    public const SLOT_HEAD = 0;
 
   36    public const SLOT_CHEST = 1;
 
   37    public const SLOT_LEGS = 2;
 
   38    public const SLOT_FEET = 3;
 
   40    public function __construct(
 
   43        parent::__construct(4);
 
   48    public function getHolder() : 
Living{
 
   52    public function getHelmet() : 
Item{
 
   53        return $this->
getItem(self::SLOT_HEAD);
 
   56    public function getChestplate() : 
Item{
 
   57        return $this->
getItem(self::SLOT_CHEST);
 
   60    public function getLeggings() : 
Item{
 
   61        return $this->
getItem(self::SLOT_LEGS);
 
   64    public function getBoots() : 
Item{
 
   65        return $this->
getItem(self::SLOT_FEET);
 
   68    public function setHelmet(
Item $helmet) : 
void{
 
   69        $this->
setItem(self::SLOT_HEAD, $helmet);
 
   72    public function setChestplate(
Item $chestplate) : 
void{
 
   73        $this->
setItem(self::SLOT_CHEST, $chestplate);
 
   76    public function setLeggings(
Item $leggings) : 
void{
 
   77        $this->
setItem(self::SLOT_LEGS, $leggings);
 
   80    public function setBoots(
Item $boots) : 
void{
 
   81        $this->
setItem(self::SLOT_FEET, $boots);
 
   85        if($item instanceof 
Armor){
 
   86            if($item->getArmorSlot() !== $slot){
 
   90            if(!($slot === ArmorInventory::SLOT_HEAD && $item instanceof 
ItemBlock && (
 
   91                    $item->
getBlock()->getTypeId() === BlockTypeIds::CARVED_PUMPKIN ||
 
   92                    $item->
getBlock()->getTypeId() === BlockTypeIds::MOB_HEAD