コード例 #1
0
 protected override void Unload()
 {
     if (Instance.Configuration.Instance.EnablePlugin)
     {
         Instance       = null;
         ConfigPubJobs  = null;
         ConfigPrivJobs = null;
         Applications   = null;
     }
     U.Events.OnPlayerDisconnected -= Events_OnPlayerDisconnected;
     Logger.Log("Jobs has been unloaded!", ConsoleColor.DarkGreen);
 }
コード例 #2
0
        protected override void Load()
        {
            Instance = this;
            if (!Instance.Configuration.Instance.EnablePlugin)
            {
                base.Unload();
                return;
            }

            ConfigPubJobs  = Configuration.Instance.PublicJobs;
            ConfigPrivJobs = Configuration.Instance.PrivateJobs;
            Applications   = new Dictionary <CSteamID, string>();

            U.Events.OnPlayerDisconnected += Events_OnPlayerDisconnected;

            Logger.Log("Jobs, by persiafighter, has been loaded!", ConsoleColor.DarkGreen);
        }