protected override void OnDispose() { ServiceRegistry.GetService<AudioService>().StopMusic(); ServiceRegistry.Unregister<LoginModel>(); Client.Dispose(); Client = null; m_UserInterface.Reset(); m_SceneManager.CurrentState = null; m_SceneManager = null; }
protected override void OnInitialize() { ServiceRegistry.GetService<UltimaGame>().SetupWindowForLogin(); m_UserInterface = ServiceRegistry.GetService<UserInterfaceService>(); m_UserInterface.Cursor = new UltimaCursor(); m_SceneManager = new StateManager(); m_SceneManager.ResetToLoginScreen(); ServiceRegistry.GetService<AudioService>().PlayMusic(0); }