public bool Unload()
        {
            try
            {
                if (!Enabled)
                {
                    return(true);
                }

                PointBlankLogging.Log("Stopping " + Name + "...");

                SaveConfiguration();                                                               // Save the configuration
                SaveTranslation();                                                                 // Save the translation
                PointBlankPluginEvents.RunPluginStop(PluginClass);                                 // Run the stop event
                PluginClass.Unload();                                                              // Run the unload function
                PointBlankPluginEvents.RunPluginUnloaded(PluginClass);                             // Run the unloaded event

                Enviroment.runtimeObjects["Plugins"].RemoveCodeObject(PluginClass.GetType().Name); // Remove the plugin from gameobject

                Enabled = false;                                                                   // Set the enabled to false
                t.Abort();                                                                         // Abort the thread
                return(true);
            }
            catch (Exception ex)
            {
                PointBlankLogging.LogError("Error stopping plugin: " + Name, ex);
                return(false);
            }
        }
        public bool Load()
        {
            try
            {
                if (Enabled)
                {
                    return(true);
                }

                PointBlankLogging.Log("Starting " + Name + "...");
                Type _class = PluginAssembly.GetTypes().First(a => a.IsClass && typeof(PointBlankPlugin).IsAssignableFrom(a)); // Get the first plugin class

                PluginClass = Enviroment.runtimeObjects["Plugins"].AddCodeObject(_class) as PointBlankPlugin;                  // Instentate the plugin class
                Name        = PluginClass.GetType().Name;                                                                      // Change the name
                Version     = PluginClass.Version;

                if (CheckUpdates())
                {
                    if (PluginConfiguration.NotifyUpdates)
                    {
                        Notify();
                    }
                    if (PluginConfiguration.AutoUpdate)
                    {
                        Update();
                    }
                }

                LoadConfiguration();                                 // Load the configuration
                LoadTranslation();                                   // Load the translation
                PointBlankPluginEvents.RunPluginStart(PluginClass);  // Run the start event
                PluginClass.Load();                                  // Run the load function
                PointBlankPluginEvents.RunPluginLoaded(PluginClass); // Run the loaded event

                Enabled = true;                                      // Set the enabled to true
                t.Start();                                           // Start the thread
                return(true);
            }
            catch (Exception ex)
            {
                PointBlankLogging.LogError("Error starting plugin: " + Name, ex);
                Unload();
                return(false);
            }
        }