Skip to content
This repository was archived by the owner on Jul 7, 2020. It is now read-only.

Commit 1f4a3cd

Browse files
authored
Armor and inventory split pmmp fix v1.1.9 (#53)
* v1.1.9 * Update Kit.php
1 parent 079646d commit 1f4a3cd

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

plugin.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: KitUI
22
author: Infernus101
33
api: [3.0.0-ALPHA1, 3.0.0-ALPHA2, 3.0.0-ALPHA3, 3.0.0-ALPHA4, 3.0.0-ALPHA5, 3.0.0-ALPHA6, 3.0.0-ALPHA7, 3.0.0-ALPHA8, 3.0.0-ALPHA9, 3.0.0-ALPHA10]
44
main: Infernus101\KitUI\Main
5-
version: 1.1.8
5+
version: 1.1.9
66
permission: # kit permissions - kit.<kit name>
77
kit.command:
88
description: kit command!

src/Infernus101/KitUI/Kit.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ public function getName() : string{
4242

4343
public function add(Player $player){
4444
$inv = $player->getInventory();
45+
$arm = $player->getArmorInventory();
4546

4647
if($this->pl->config->get("clear-inventory")){
4748
$inv->clearAll();
@@ -64,10 +65,10 @@ public function add(Player $player){
6465
}
6566
}
6667

67-
isset($this->data["helmet"]) and $inv->setHelmet($this->loadItem(...explode(":", $this->data["helmet"])));
68-
isset($this->data["chestplate"]) and $inv->setChestplate($this->loadItem(...explode(":", $this->data["chestplate"])));
69-
isset($this->data["leggings"]) and $inv->setLeggings($this->loadItem(...explode(":", $this->data["leggings"])));
70-
isset($this->data["boots"]) and $inv->setBoots($this->loadItem(...explode(":", $this->data["boots"])));
68+
isset($this->data["helmet"]) and $arm->setHelmet($this->loadItem(...explode(":", $this->data["helmet"])));
69+
isset($this->data["chestplate"]) and $arm->setChestplate($this->loadItem(...explode(":", $this->data["chestplate"])));
70+
isset($this->data["leggings"]) and $arm->setLeggings($this->loadItem(...explode(":", $this->data["leggings"])));
71+
isset($this->data["boots"]) and $arm->setBoots($this->loadItem(...explode(":", $this->data["boots"])));
7172

7273
if(isset($this->data["effects"])){
7374
foreach($this->data["effects"] as $effectString){

0 commit comments

Comments
 (0)