Further work on refactor to interface based scripts
This commit is contained in:
@@ -7,11 +7,10 @@ namespace PkmnLib.Plugin.Gen7.Scripts.Abilities;
|
||||
/// <see href="https://bulbapedia.bulbagarden.net/wiki/Galvanize_(Ability)">Bulbapedia - Galvanize</see>
|
||||
/// </summary>
|
||||
[Script(ScriptCategory.Ability, "galvanize")]
|
||||
public class Galvanize : Script
|
||||
public class Galvanize : Script, IScriptChangeMoveType
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public override void ChangeMoveType(IExecutingMove move, IPokemon target, byte hit,
|
||||
ref TypeIdentifier? typeIdentifier)
|
||||
public 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))
|
||||
|
||||
Reference in New Issue
Block a user