コード例 #1
0
ファイル: World.cs プロジェクト: Sedatb23/Kapitein-Kat
 public void Reset()
 {
     Game1.BackgroundImage = AssetManager.Textures[Enums.Assets.BACKGROUND];
     _screenType = Enums.ScreenType.STARTSCREEN;
     _startScreen = new Screens.StartScreen(_game);
     _gameplay = new Screens.GamePlay(_game);
     _story = new Screens.Story(_game);
     _highscore = new Screens.Highscore(_game);
     _tutorial = new Screens.Tutorial(_game);
     _endScreen = new Screens.EndScreen(_game);
     BGMusic = AssetManager.Sounds[Enums.Sounds.MUSIC_BG_MENU];
     _bgMusic.Dispose();
     _bgMusic = BGMusic.CreateInstance();
     _bgMusic.IsLooped = true;
     _bgMusic.Play();
     Objects.Player.Name = "";
 }
コード例 #2
0
ファイル: World.cs プロジェクト: Sedatb23/Kapitein-Kat
 public World(Game1 game)
 {
     _game = game;
     AssetManager.LoadContent(game);
     Game1.BackgroundImage = AssetManager.Textures[Enums.Assets.BACKGROUND];
     _screenType = Enums.ScreenType.STARTSCREEN;
     _startScreen = new Screens.StartScreen(game);
     _gameplay = new Screens.GamePlay(game);
     _story = new Screens.Story(game);
     _highscore = new Screens.Highscore(game);
     _tutorial = new Screens.Tutorial(game);
     _endScreen = new Screens.EndScreen(game);
     BGMusic = AssetManager.Sounds[Enums.Sounds.MUSIC_BG_MENU]; 
     _bgMusic = BGMusic.CreateInstance();
     _bgMusic.IsLooped = true;
     _bgMusic.Play();
 }