Cleanup, move OnBeforeAnyHookInvoked function to an interface
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
namespace PkmnLib.Plugin.Gen7.Scripts.Battle;
|
||||
|
||||
[Script(ScriptCategory.Battle, "magic_room")]
|
||||
public class MagicRoomEffect : Script
|
||||
public class MagicRoomEffect : Script, IScriptOnBeforeAnyHookInvoked
|
||||
{
|
||||
private int _turnsLeft = 5;
|
||||
|
||||
@@ -12,7 +12,7 @@ public class MagicRoomEffect : Script
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override void OnBeforeAnyHookInvoked(ref List<ScriptCategory>? suppressedCategories)
|
||||
public void OnBeforeAnyHookInvoked(ref List<ScriptCategory>? suppressedCategories)
|
||||
{
|
||||
suppressedCategories ??= [];
|
||||
suppressedCategories.Add(ScriptCategory.ItemBattleTrigger);
|
||||
|
||||
Reference in New Issue
Block a user