namespace PkmnLib.Plugin.Gen7.Scripts.Abilities;
///
/// PreventCritical is a generic ability that prevents the user from being hit by critical hits.
/// This ability completely blocks any incoming critical hits from opposing Pokémon.
/// This ability is used by abilities like Battle Armor and Shell Armor.
///
/// Bulbapedia - Battle Armor
/// Bulbapedia - Shell Armor
///
[Script(ScriptCategory.Ability, "prevent_critical")]
public class PreventCritical : Script, IScriptBlockIncomingCriticalHit
{
///
public void BlockIncomingCriticalHit(IExecutingMove move, IPokemon target, byte hit, ref bool block) =>
block = true;
}