Enum Reduction
#[non_exhaustive]pub enum Reduction {
Invulnerability,
Armor,
Enchantments,
MobEffects,
Absorption,
InnateResistance,
}Expand description
What took a share of a hit before the health, as NeoForge’s DamageContainer.Reduction
names it.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Invulnerability
The damage cooldown: what the last hit already dealt (lastHurt), taken off a hit
that lands within it.
Armor
Armor and toughness (getDamageAfterArmorAbsorb).
Enchantments
Protection enchantments (EnchantmentHelper.getDamageProtection).
MobEffects
Resistance (getDamageAfterMagicAbsorb’s mob effect step).
Absorption
The absorption hearts.
InnateResistance
What the entity’s own kind resists: a witch’s magic resistance.
Trait Implementations§
impl Copy for Reduction
impl Eq for Reduction
impl StructuralPartialEq for Reduction
Auto Trait Implementations§
impl Freeze for Reduction
impl RefUnwindSafe for Reduction
impl Send for Reduction
impl Sync for Reduction
impl Unpin for Reduction
impl UnsafeUnpin for Reduction
impl UnwindSafe for Reduction
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more