tridents/xbows WIP part 1

This commit is contained in:
nossr50
2020-07-06 20:44:10 -07:00
parent 919907f46a
commit ea448dfa47
29 changed files with 622 additions and 36 deletions

View File

@@ -25,6 +25,11 @@ public final class ItemUtils {
return mcMMO.getMaterialMapStore().isBow(item.getType().getKey().getKey());
}
public static boolean isCrossbow(ItemStack itemStack) {
return mcMMO.getMaterialMapStore().isCrossbow(itemStack.getType().getKey().getKey());
}
public static boolean hasItemInEitherHand(Player player, Material material) {
return player.getInventory().getItemInMainHand().getType() == material || player.getInventory().getItemInOffHand().getType() == material;
}
@@ -39,6 +44,11 @@ public final class ItemUtils {
return mcMMO.getMaterialMapStore().isSword(item.getType().getKey().getKey());
}
public static boolean isTrident(ItemStack itemStack) {
return mcMMO.getMaterialMapStore().isTrident(itemStack.getType().getKey().getKey());
}
/**
* Checks if the item is a hoe.
*