public static class ISpecialArmor.ArmorProperties extends java.lang.Object implements java.lang.Comparable<ISpecialArmor.ArmorProperties>
Modifier and Type | Field and Description |
---|---|
int |
AbsorbMax |
double |
AbsorbRatio |
double |
Armor |
private static boolean |
DEBUG |
int |
Priority |
int |
Slot |
double |
Toughness |
Constructor and Description |
---|
ArmorProperties(int priority,
double ratio,
int max) |
Modifier and Type | Method and Description |
---|---|
static float |
applyArmor(EntityLivingBase entity,
NonNullList<ItemStack> inventory,
DamageSource source,
double damage)
Gathers and applies armor reduction to damage being dealt to a entity.
|
int |
compareTo(ISpecialArmor.ArmorProperties o) |
ISpecialArmor.ArmorProperties |
copy() |
private static void |
StandardizeList(ISpecialArmor.ArmorProperties[] armor,
double damage)
Sorts and standardizes the distribution of damage over armor.
|
java.lang.String |
toString() |
public int Priority
public int AbsorbMax
public double AbsorbRatio
public double Armor
public double Toughness
public int Slot
private static final boolean DEBUG
public static float applyArmor(EntityLivingBase entity, NonNullList<ItemStack> inventory, DamageSource source, double damage)
entity
- The Entity being damageinventory
- An array of armor itemssource
- The damage source typedamage
- The total damage being doneprivate static void StandardizeList(ISpecialArmor.ArmorProperties[] armor, double damage)
armor
- The armor informationdamage
- The total damage being receivedpublic int compareTo(ISpecialArmor.ArmorProperties o)
compareTo
in interface java.lang.Comparable<ISpecialArmor.ArmorProperties>
public java.lang.String toString()
toString
in class java.lang.Object
public ISpecialArmor.ArmorProperties copy()