public static void Load(ScreenManager screenManager, params GameScreen[] screensToLoad) { foreach (GameScreen screen in screenManager.GetScreens()) screen.ExitScreen(); LoadingScreen loadingScreen = new LoadingScreen(screenManager, screensToLoad); screenManager.AddScreen(loadingScreen); }
public static void Load(ScreenManager screenManager, params GameScreen[] screensToLoad) { foreach (GameScreen screen in screenManager.GetScreens()) screen.ExitScreen(); bool wait = false; if (!(screensToLoad[0] is MenuScreen)) { AudioManager.FadeSong(0.0f, TimeSpan.FromSeconds(2)); wait = true; } LoadingScreen loadingScreen = new LoadingScreen(screenManager, screensToLoad, wait); screenManager.AddScreen(loadingScreen); }