public void OnShutdown() { if (!this.IsShuttingDown) { this.libperm.SaveData(); this.IsShuttingDown = true; this.UnloadAllPlugins(null); foreach (Extension allExtension in this.extensionManager.GetAllExtensions()) { allExtension.OnShutdown(); } foreach (string library in this.extensionManager.GetLibraries()) { this.extensionManager.GetLibrary(library).Shutdown(); } Oxide.Core.RemoteConsole.RemoteConsole remoteConsole = this.RemoteConsole; if (remoteConsole != null) { remoteConsole.Shutdown("Server shutting down", CloseStatusCode.Normal); } else { } Oxide.Core.ServerConsole.ServerConsole serverConsole = this.ServerConsole; if (serverConsole != null) { serverConsole.OnDisable(); } else { } this.RootLogger.Shutdown(); } }
public void OnShutdown() { IsShuttingDown = true; UnloadAllPlugins(); foreach (var extension in extensionmanager.GetAllExtensions()) { extension.OnShutdown(); } ServerConsole?.OnDisable(); }
public void OnShutdown() { if (IsShuttingDown) { return; } IsShuttingDown = true; UnloadAllPlugins(); foreach (var extension in extensionManager.GetAllExtensions()) { extension.OnShutdown(); } foreach (var name in extensionManager.GetLibraries()) { extensionManager.GetLibrary(name).Shutdown(); } ServerConsole?.OnDisable(); RootLogger.Shutdown(); }
/// <summary> /// Called when the server is shutting down /// </summary> public void OnShutdown() { if (!IsShuttingDown) { libperm.SaveData(); IsShuttingDown = true; UnloadAllPlugins(); foreach (Extension extension in extensionManager.GetAllExtensions()) { extension.OnShutdown(); } foreach (string name in extensionManager.GetLibraries()) { extensionManager.GetLibrary(name).Shutdown(); } RemoteConsole?.Shutdown(); ServerConsole?.OnDisable(); RootLogger.Shutdown(); } }