mirror of
https://github.com/songoda/EpicFarming.git
synced 2024-09-30 23:57:29 +02:00
fixed error regarding breeding of unbreedable entities
This commit is contained in:
parent
615a23ab56
commit
4d4c43e006
@ -163,8 +163,12 @@ public class EntityTask extends BukkitRunnable {
|
||||
|
||||
ItemStack item = inventory.getItem(i);
|
||||
|
||||
if (item.getType() != EntityInfo.valueOf(entityType.name()).getMaterial() || item.getAmount() < 2)
|
||||
try {
|
||||
if (item.getType() != EntityInfo.valueOf(entityType.name()).getMaterial() || item.getAmount() < 2)
|
||||
continue;
|
||||
} catch (IllegalArgumentException e) {
|
||||
continue;
|
||||
}
|
||||
|
||||
int newAmt = item.getAmount() - 2;
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
name: EpicFarming
|
||||
description: EpicFarming
|
||||
main: com.songoda.epicfarming.EpicFarmingPlugin
|
||||
version: 2.0.16
|
||||
version: 2.0.17
|
||||
depend: [Arconix]
|
||||
soft-depend: [Multiverse-Core]
|
||||
author: Songoda
|
||||
|
Loading…
Reference in New Issue
Block a user