-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPlugin.cs
More file actions
45 lines (32 loc) · 1.37 KB
/
Plugin.cs
File metadata and controls
45 lines (32 loc) · 1.37 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
using System;
using Exiled.API.Features;
using OverwatchLogger.Features;
namespace OverwatchLogger
{
public class Plugin: Plugin<Config>
{
public static Plugin Instance { get; private set; }
public override string Author { get; } = "notifapi";
public override Version RequiredExiledVersion { get; } = new Version(9, 0 ,0);
public override Version Version { get; } = new Version(2, 0, 1);
public override bool IgnoreRequiredVersionCheck { get; } = false;
public override void OnEnabled()
{
Instance = this;
HookHelper.Start();
Exiled.Events.Handlers.Server.WaitingForPlayers += EventHandler.OnWaitingForPlayers;
Exiled.Events.Handlers.Server.RoundEnded += EventHandler.OnRoundEnded;
Exiled.Events.Handlers.Player.Spawned += EventHandler.OnSpawned;
base.OnEnabled();
}
public override void OnDisabled()
{
Exiled.Events.Handlers.Server.WaitingForPlayers -= EventHandler.OnWaitingForPlayers;
Exiled.Events.Handlers.Server.RoundEnded -= EventHandler.OnRoundEnded;
Exiled.Events.Handlers.Player.Spawned -= EventHandler.OnSpawned;
HookHelper.Stop();
Instance = null;
base.OnDisabled();
}
}
}