public UpdateManager() { myLogger = new Logger("UpdateManager", () => string.Empty, () => { return ManagerStatus.ToString(); }); ThreadTracker.SetGameThread(); Instance = this; }
protected override void UnloadData() { base.UnloadData(); if (MyAPIGateway.Entities != null) MyAPIGateway.Entities.OnEntityAdd -= Entities_OnEntityAdd; ManagerStatus = Status.Terminated; UpdateRegistrar = null; AllBlockScriptConstructors = null; EveryBlockScriptConstructors = null; CharacterScriptConstructors = null; PlayerScriptConstructors = null; GridScriptConstructors = null; PlayerLeaves = null; AnyPlayerLeaves = null; playersAPI = null; playersCached = null; AddRemoveActions = null; CubeBlocks = null; Characters = null; Instance = null; Profiler.Write(); }