More work on refactor to interfaces
All checks were successful
Build / Build (push) Successful in 50s
All checks were successful
Build / Build (push) Successful in 50s
This commit is contained in:
@@ -6,7 +6,7 @@ namespace PkmnLib.Plugin.Gen7.Scripts.Abilities;
|
||||
/// <see href="https://bulbapedia.bulbagarden.net/wiki/Schooling_(Ability)">Bulbapedia - Schooling</see>
|
||||
/// </summary>
|
||||
[Script(ScriptCategory.Ability, "schooling")]
|
||||
public class Schooling : Script
|
||||
public class Schooling : Script, IScriptOnEndTurn
|
||||
{
|
||||
private IPokemon? _owningPokemon;
|
||||
|
||||
@@ -22,7 +22,7 @@ public class Schooling : Script
|
||||
public override void OnSwitchIn(IPokemon pokemon, byte position) => ChangeFormIfNeeded(pokemon);
|
||||
|
||||
/// <inheritdoc />
|
||||
public override void OnEndTurn(IScriptSource owner, IBattle battle) => ChangeFormIfNeeded(_owningPokemon);
|
||||
public void OnEndTurn(IScriptSource owner, IBattle battle) => ChangeFormIfNeeded(_owningPokemon);
|
||||
|
||||
private static void ChangeFormIfNeeded(IPokemon? pokemon)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user