namespace PkmnLib.Plugin.Gen7.Scripts.Abilities;

/// <summary>
/// Moxie is an ability that raises the user's Attack stat after knocking out a Pokémon.
///
/// <see href="https://bulbapedia.bulbagarden.net/wiki/Moxie_(Ability)">Bulbapedia - Moxie</see>
/// </summary>
[Script(ScriptCategory.Ability, "moxie")]
public class Moxie : Script, IScriptOnOpponentFaints
{
    /// <inheritdoc />
    public void OnOpponentFaints(IExecutingMove move, IPokemon target, byte hit)
    {
        move.User.ChangeStatBoost(Statistic.Attack, 1, true, false);
    }
}