namespace PkmnLib.Plugin.Gen7.Scripts.Abilities;

/// <summary>
/// Super Luck is an ability that increases the critical hit ratio of the Pokémon's moves.
///
/// <see href="https://bulbapedia.bulbagarden.net/wiki/Super_Luck_(Ability)">Bulbapedia - Super Luck</see>
/// </summary>
[Script(ScriptCategory.Ability, "super_luck")]
public class SuperLuck : Script, IScriptChangeCriticalStage
{
    /// <inheritdoc />
    public void ChangeCriticalStage(IExecutingMove move, IPokemon target, byte hit, ref byte stage)
    {
        if (stage == byte.MaxValue)
            return;
        stage++;
    }
}