java.lang.Object
com.pixelmonmod.pixelmon.api.pokemon.ability.AbstractAbility
com.pixelmonmod.pixelmon.api.pokemon.ability.abilities.Absorb
All Implemented Interfaces:
Ability, RarityTweak, ITranslatable
Direct Known Subclasses:
VoltAbsorb, WaterAbsorb

public class Absorb extends AbstractAbility
Heals 25% hp when hit by a certain type of move.
  • Constructor Details

    • Absorb

      protected Absorb(Element type, String langString)
      Initializes an absorb Ability.
      Parameters:
      type - The type that the Ability grants an immunity to.
      langString - The lang string to display when the Ability activates.
  • Method Details

    • allowsIncomingAttack

      public boolean allowsIncomingAttack(PixelmonWrapper pokemon, PixelmonWrapper user, Attack a)
      Description copied from interface: Ability
      Determines whether an incoming attack can hit the Pokémon
      Parameters:
      pokemon - The Pokémon with the Ability.
      user - The attack's user.
      a - The attack.
      Returns:
      Whether the attack can hit the Pokémon.