public class DamageEnchantment extends Enchantment
Enchantment.Rarity| Modifier and Type | Field and Description |
|---|---|
private static int[] |
field_9063 |
private static int[] |
field_9064 |
private static int[] |
field_9066 |
int |
typeIndex |
private static String[] |
typeNames |
translationKey, type| Constructor and Description |
|---|
DamageEnchantment(Enchantment.Rarity weight,
int typeIndex,
EquipmentSlot[] slots) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canAccept(Enchantment other)
Returns whether this enchantment can exist on an item stack with the
other enchantment. |
float |
getAttackDamage(int level,
EntityGroup group) |
int |
getMaxLevel() |
int |
getMaxPower(int level) |
int |
getMinPower(int level) |
boolean |
isAcceptableItem(ItemStack stack) |
void |
onTargetDamaged(LivingEntity user,
Entity target,
int level) |
byRawId, canCombine, getEquipment, getMinLevel, getName, getOrCreateTranslationKey, getProtectionAmount, getRarity, getTranslationKey, isAvailableForEnchantedBookOffer, isAvailableForRandomSelection, isCursed, isTreasure, onUserDamagedprivate static final String[] typeNames
private static final int[] field_9063
private static final int[] field_9066
private static final int[] field_9064
public final int typeIndex
public DamageEnchantment(Enchantment.Rarity weight, int typeIndex, EquipmentSlot[] slots)
public int getMinPower(int level)
getMinPower in class Enchantmentpublic int getMaxPower(int level)
getMaxPower in class Enchantmentpublic int getMaxLevel()
getMaxLevel in class Enchantmentpublic float getAttackDamage(int level,
EntityGroup group)
getAttackDamage in class Enchantmentpublic boolean canAccept(Enchantment other)
other enchantment.canAccept in class Enchantmentpublic boolean isAcceptableItem(ItemStack stack)
isAcceptableItem in class Enchantmentpublic void onTargetDamaged(LivingEntity user, Entity target, int level)
onTargetDamaged in class Enchantment