namespace PkmnLib.Plugin.Gen7.Scripts.Abilities; /// /// Galvanize is an ability that turns Normal-type moves into Electric-type moves and boosts their power. /// This ability is exclusive to Alolan Golem. /// /// Bulbapedia - Galvanize /// [Script(ScriptCategory.Ability, "galvanize")] public class Galvanize : Script { /// public override void ChangeMoveType(IExecutingMove move, IPokemon target, byte hit, ref TypeIdentifier? typeIdentifier) { if (typeIdentifier?.Name == "normal" && move.Battle.Library.StaticLibrary.Types.TryGetTypeIdentifier("electric", out var electricType)) { typeIdentifier = electricType; } } /// public override void ChangeDamageModifier(IExecutingMove move, IPokemon target, byte hit, ref float modifier) { if (move.GetHitData(target, hit).Type?.Name == "electric") modifier *= 1.2f; } }