public override void Initialize() { ServerApi.Hooks.GameUpdate.Register(this, OnUpdate); ServerApi.Hooks.NetGreetPlayer.Register(this, OnGreetPlayer); ServerApi.Hooks.GameInitialize.Register(this, OnInitialize); ServerApi.Hooks.ServerLeave.Register(this, OnLeave); Config = new PvPConfig(); }
private static void SetUpConfig() { var configPath = Path.Combine(TShock.SavePath, "PvPtoggle.json"); (Config = PvPConfig.Read(configPath)).Write(configPath); }