Fixed mis-uses of Item->isTool()

this has been wrongly used to indicate a durable item, but not just tools are durable items.
This commit is contained in:
Dylan K. Taylor
2018-05-01 20:05:02 +01:00
parent 5368120f13
commit 0247dff909
2 changed files with 3 additions and 2 deletions

View File

@ -164,7 +164,7 @@ class Item implements ItemIds, \JsonSerializable{
public static function getCreativeItemIndex(Item $item) : int{
foreach(Item::$creative as $i => $d){
if($item->equals($d, !$item->isTool())){
if($item->equals($d, !($item instanceof Durable))){
return $i;
}
}