21 lines
743 B
C#
21 lines
743 B
C#
namespace PkmnLib.Plugin.Gen7.Scripts.Abilities;
|
|
|
|
/// <summary>
|
|
/// Damp is an ability that prevents the use of Self-Destruct and Explosion moves.
|
|
/// When a Pokémon with this ability is on the field, any attempt to use these moves will fail.
|
|
/// This ability affects both allies and opponents.
|
|
///
|
|
/// <see href="https://bulbapedia.bulbagarden.net/wiki/Damp_(Ability)">Bulbapedia - Damp</see>
|
|
/// </summary>
|
|
[Script(ScriptCategory.Ability, "damp")]
|
|
public class Damp : Script
|
|
{
|
|
/// <inheritdoc />
|
|
public override void FailIncomingMove(IExecutingMove move, IPokemon target, ref bool fail)
|
|
{
|
|
if (move.UseMove.Name == "self_destruct" || move.UseMove.Name == "explosion")
|
|
{
|
|
fail = true;
|
|
}
|
|
}
|
|
} |