Exemplo n.º 1
0
        /// <summary>
        /// Unregisters the events required for the plugin to fuction properly.
        /// </summary>
        private void UnregisterEvents()
        {
            server               = null;
            player               = null;
            Serv.RoundStarted   -= server.OnRoundStart;
            Serv.RespawningTeam -= server.OnRespawnTeam;

            Play.Destroying -= player.OnLeft;
            Play.Died       -= player.OnDied;
        }
Exemplo n.º 2
0
        /// <summary>
        /// Registers events required for the plugin to function properly.
        /// </summary>
        private void RegisterEvents()
        {
            server               = new Handlers.Server();
            player               = new Handlers.Player();
            Serv.RoundStarted   += server.OnRoundStart;
            Serv.RespawningTeam += server.OnRespawnTeam;

            Play.Destroying += player.OnLeft;
            Play.Died       += player.OnDied;
        }