diff --git a/Output/Languages/en.xml b/Output/Languages/en.xml index 76826115..2fdd465c 100644 --- a/Output/Languages/en.xml +++ b/Output/Languages/en.xml @@ -20,6 +20,10 @@ Duet Medley Short version + Normal + Instrumental + Karaoke + Karaoke Vocal Hero Superstar Lead Singer diff --git a/Output/PartyModes/Challenge/Themes/Default.xml b/Output/PartyModes/Challenge/Themes/Default.xml index 42878207..ee539afb 100644 --- a/Output/PartyModes/Challenge/Themes/Default.xml +++ b/Output/PartyModes/Challenge/Themes/Default.xml @@ -1,6 +1,6 @@  - 7 + 8 Default brunzel diff --git a/Output/PartyModes/TicTacToe/Themes/Default.xml b/Output/PartyModes/TicTacToe/Themes/Default.xml index 42878207..ee539afb 100644 --- a/Output/PartyModes/TicTacToe/Themes/Default.xml +++ b/Output/PartyModes/TicTacToe/Themes/Default.xml @@ -1,6 +1,6 @@  - 7 + 8 Default brunzel diff --git a/Output/Themes/Changelog/Changelog_ScreenSong.txt b/Output/Themes/Changelog/Changelog_ScreenSong.txt index 7b5e00a2..69e7e899 100644 --- a/Output/Themes/Changelog/Changelog_ScreenSong.txt +++ b/Output/Themes/Changelog/Changelog_ScreenSong.txt @@ -1,5 +1,13 @@ ScreenSong +++++++++++ +Version 11: + +Add: + + +++++++++++ + ++++++++++ Version 10: diff --git a/Output/Themes/Changelog/Changelog_ThemeSystem.txt b/Output/Themes/Changelog/Changelog_ThemeSystem.txt index 0724bbe4..ecfa9a36 100644 --- a/Output/Themes/Changelog/Changelog_ThemeSystem.txt +++ b/Output/Themes/Changelog/Changelog_ThemeSystem.txt @@ -1,5 +1,12 @@ Theme System +++++++++++ +Version 8 + +Changed: +SelectSlide for AudioMode (SelectSlideOptionsAudioMode) on song select screen + + ++++++++++ Version 7 diff --git a/Output/Themes/Vocaluxe 2024.xml b/Output/Themes/Vocaluxe 2024.xml index bc94d4bd..d3ab2946 100644 --- a/Output/Themes/Vocaluxe 2024.xml +++ b/Output/Themes/Vocaluxe 2024.xml @@ -1,6 +1,6 @@  - 7 + 8 Vocaluxe 2024 Vocaluxe diff --git a/Output/Themes/Vocaluxe 2024/Screens/ScreenSong.xml b/Output/Themes/Vocaluxe 2024/Screens/ScreenSong.xml index 8e8fc4ec..33a7f33e 100644 --- a/Output/Themes/Vocaluxe 2024/Screens/ScreenSong.xml +++ b/Output/Themes/Vocaluxe 2024/Screens/ScreenSong.xml @@ -2,7 +2,7 @@ ScreenSong - 10 + 11 @@ -251,7 +251,7 @@ 330 - 70.5 + 60 -2.11 51 525 @@ -513,7 +513,7 @@ SongSelectButton 60 - 352.5 + 395 540 60 -2.11 @@ -540,7 +540,7 @@ SongSelectButton 60 - 135 + 110 540 60 -2.11 @@ -818,7 +818,7 @@ SongSelectButton 60 - 435 + 472.5 540 60 -2.11 @@ -1176,21 +1176,63 @@ SelectSlideArrowRight 60 - 202.5 + 177.5 540 60 -2.11 67.5 - 210 + 185 45 45 -2.12 547.5 - 210 + 185 + 45 + 45 + -2.12 + + + + + + + + 37.5 + 75 + 0 + 420 + Outline + Bold + 1 + + + SongSelectButton + SelectSlideArrowLeft + SelectSlideArrowRight + SongSelectButton + SelectSlideArrowLeft + SelectSlideArrowRight + + 60 + 245 + 540 + 60 + -2.11 + + + 67.5 + 252.5 + 45 + 45 + -2.12 + + + 547.5 + 252.5 45 45 -2.12 @@ -1218,21 +1260,21 @@ SelectSlideArrowRight 60 - 285 + 327.5 540 60 -2.11 67.5 - 292.5 + 335 45 45 -2.12 547.5 - 292.5 + 335 45 45 -2.12 diff --git a/Vocaluxe/Base/ThemeSystem/CTheme.cs b/Vocaluxe/Base/ThemeSystem/CTheme.cs index 915ec503..20c0ac4a 100644 --- a/Vocaluxe/Base/ThemeSystem/CTheme.cs +++ b/Vocaluxe/Base/ThemeSystem/CTheme.cs @@ -29,7 +29,7 @@ namespace Vocaluxe.Base.ThemeSystem abstract class CTheme { // Version number for theme files. Increment it, if you've changed something on the theme files! - private const int _ThemeSystemVersion = 7; + private const int _ThemeSystemVersion = 8; protected STheme _Data; public String Name diff --git a/Vocaluxe/Screens/CScreenHighscore.cs b/Vocaluxe/Screens/CScreenHighscore.cs index 1ff08446..8f5b260d 100644 --- a/Vocaluxe/Screens/CScreenHighscore.cs +++ b/Vocaluxe/Screens/CScreenHighscore.cs @@ -240,6 +240,10 @@ namespace Vocaluxe.Screens if (points == null) return; + // No points in Karaoke Mode + if (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_KARAOKE) + return; + for (int round = 0; round < points.NumRounds; round++) { SPlayer[] players = points.GetPlayer(round, CGame.NumPlayers); diff --git a/Vocaluxe/Screens/CScreenScore.cs b/Vocaluxe/Screens/CScreenScore.cs index a66d644d..234d03cf 100644 --- a/Vocaluxe/Screens/CScreenScore.cs +++ b/Vocaluxe/Screens/CScreenScore.cs @@ -169,7 +169,9 @@ namespace Vocaluxe.Screens { string rating; - if (points >= 9800) + if (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_KARAOKE) + rating = "TR_RATING_KARAOKE"; + else if (points >= 9800) rating = "TR_RATING_VOCAL_HERO"; else if (points >= 8400) rating = "TR_RATING_SUPERSTAR"; @@ -257,6 +259,12 @@ namespace Vocaluxe.Screens private void _PlayApplauseSound(int maxPoints) { + // Play no applause sound based on Karaoke Mode + if (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_KARAOKE) + { + return; + } + // Play the appropriate applause sound based on maxPoints if (maxPoints >= 8000) { @@ -356,19 +364,23 @@ namespace Vocaluxe.Screens private void _SetVisibility() { + bool isKaraokeMode = CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_KARAOKE; + for (int numplayer = 0; numplayer < CSettings.MaxNumPlayer; numplayer++) { for (int player = 0; player < CSettings.MaxNumPlayer; player++) { if (player <= numplayer) { - _Texts[_TextNames[player, numplayer]].Visible = numplayer + 1 == CGame.NumPlayers; - _Texts[_TextScores[player, numplayer]].Visible = numplayer + 1 == CGame.NumPlayers; - _Texts[_TextRatings[player, numplayer]].Visible = numplayer + 1 == CGame.NumPlayers; - _Texts[_TextDifficulty[player, numplayer]].Visible = numplayer + 1 == CGame.NumPlayers; - _ProgressBars[_ProgressBarPoints[player, numplayer]].Visible = numplayer + 1 == CGame.NumPlayers; + bool isVisible = numplayer + 1 == CGame.NumPlayers; + + _Texts[_TextNames[player, numplayer]].Visible = isVisible; + _Texts[_TextScores[player, numplayer]].Visible = isVisible && !isKaraokeMode; + _Texts[_TextRatings[player, numplayer]].Visible = isVisible; + _Texts[_TextDifficulty[player, numplayer]].Visible = isVisible; + _ProgressBars[_ProgressBarPoints[player, numplayer]].Visible = isVisible && !isKaraokeMode; _ProgressBars[_ProgressBarPoints[player, numplayer]].Reset(true); - _Statics[_StaticAvatar[player, numplayer]].Visible = numplayer + 1 == CGame.NumPlayers; + _Statics[_StaticAvatar[player, numplayer]].Visible = isVisible; _Statics[_StaticAvatar[player, numplayer]].Texture = null; } diff --git a/Vocaluxe/Screens/CScreenSing.cs b/Vocaluxe/Screens/CScreenSing.cs index b7cb3b65..17abbe0e 100644 --- a/Vocaluxe/Screens/CScreenSing.cs +++ b/Vocaluxe/Screens/CScreenSing.cs @@ -1159,7 +1159,15 @@ namespace Vocaluxe.Screens _Texts[_TextSongName].Text = songname; _Texts[_TextPauseSongName].Text = songname; - _CurrentStream = CSound.Load(song.GetMP3(), false, true, CConfig.Config.Sound.KaraokeEffect == EOffOn.TR_CONFIG_ON ? EAudioEffect.Karaoke : EAudioEffect.None); + if (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_INSTRUMENTAL || CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_KARAOKE) + { + _CurrentStream = CSound.Load(song.GetInstrumental(), false, true, EAudioEffect.None); + } + else + { + _CurrentStream = CSound.Load(song.GetMP3(), false, true, CConfig.Config.Sound.KaraokeEffect == EOffOn.TR_CONFIG_ON ? EAudioEffect.Karaoke : EAudioEffect.None); + } + CSound.SetStreamVolume(_CurrentStream, 100); CSound.SetPosition(_CurrentStream, song.Start); _CurrentTime = song.Start; @@ -1399,13 +1407,26 @@ namespace Vocaluxe.Screens for (int player = 0; player < CGame.NumPlayers; player++) { - _Texts[_PlayerTextScore[player]].Visible = true; + if (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_KARAOKE) + { + _Texts[_PlayerTextScore[player]].Visible = false; + _Statics[_PlayerStaticScore[player]].Visible = false; + _ProgressBars[_PlayerProgressBarRating[player]].Visible = false; + _SingNotes[_SingBars].Visible = false; + + } + else + { + _Texts[_PlayerTextScore[player]].Visible = true; + _Statics[_PlayerStaticScore[player]].Visible = true; + _ProgressBars[_PlayerProgressBarRating[player]].Visible = true; + _SingNotes[_SingBars].Visible = true; + } + _Texts[_PlayerTextName[player]].Visible = (CConfig.Config.Theme.PlayerInfo == EPlayerInfo.TR_CONFIG_PLAYERINFO_BOTH || CConfig.Config.Theme.PlayerInfo == EPlayerInfo.TR_CONFIG_PLAYERINFO_NAME); - _Statics[_PlayerStaticScore[player]].Visible = true; _Statics[_PlayerStaticAvatar[player]].Visible = (CConfig.Config.Theme.PlayerInfo == EPlayerInfo.TR_CONFIG_PLAYERINFO_BOTH || CConfig.Config.Theme.PlayerInfo == EPlayerInfo.TR_CONFIG_PLAYERINFO_AVATAR); - _ProgressBars[_PlayerProgressBarRating[player]].Visible = true; } _Lyrics[_LyricMain].Alpha = 0f; diff --git a/Vocaluxe/Screens/CScreenSong.cs b/Vocaluxe/Screens/CScreenSong.cs index 9b468537..92d3df24 100644 --- a/Vocaluxe/Screens/CScreenSong.cs +++ b/Vocaluxe/Screens/CScreenSong.cs @@ -71,6 +71,7 @@ namespace Vocaluxe.Screens private const string _ButtonOptionsHighscore = "ButtonOptionsHighscore"; private const string _SelectSlideOptionsMode = "SelectSlideOptionsMode"; + private const string _SelectSlideOptionsAudioMode = "SelectSlideOptionsAudioMode"; private const string _SelectSlideOptionsPlaylistAdd = "SelectSlideOptionsPlaylistAdd"; private const string _SelectSlideOptionsPlaylistOpen = "SelectSlideOptionsPlaylistOpen"; private const string _SelectSlideOptionsNumMedleySongs = "SelectSlideOptionsNumMedleySongs"; @@ -105,6 +106,13 @@ namespace Vocaluxe.Screens private System.Timers.Timer _TimerShortInfoText; + private static EAudioMode _AudioMode = EAudioMode.TR_AUDIOMODE_NORMAL; + + public static EAudioMode GetAudioMode() + { + return _AudioMode; + } + private static int _StaticSelectedSongID; private static void setStaticSelectedSongID(int songID) @@ -168,7 +176,7 @@ namespace Vocaluxe.Screens _ThemeStatics = new string[] {_StaticSearchBar, _StaticOptionsBG, _StaticShortInfoTop}; _ThemeTexts = tlist.ToArray(); _ThemeButtons = blist.ToArray(); - _ThemeSelectSlides = new string[] {_SelectSlideOptionsMode, _SelectSlideOptionsPlaylistAdd, _SelectSlideOptionsPlaylistOpen, _SelectSlideOptionsNumMedleySongs}; + _ThemeSelectSlides = new string[] {_SelectSlideOptionsMode, _SelectSlideOptionsAudioMode, _SelectSlideOptionsPlaylistAdd, _SelectSlideOptionsPlaylistOpen, _SelectSlideOptionsNumMedleySongs}; _ThemeSongMenus = new string[] {_SongMenuName}; _ThemePlaylists = new string[] {_PlaylistName}; @@ -1014,6 +1022,8 @@ namespace Vocaluxe.Screens else gm = CSongs.VisibleSongs[songNr].IsDuet ? EGameMode.TR_GAMEMODE_DUET : EGameMode.TR_GAMEMODE_NORMAL; + _AudioMode = (EAudioMode)_SelectSlides[_SelectSlideOptionsAudioMode].Selection; + CGame.Reset(); CGame.ClearSongs(); @@ -1331,6 +1341,7 @@ namespace Vocaluxe.Screens private void _ToggleSongOptions(ESongOptionsView view) { _SelectSlides[_SelectSlideOptionsMode].Visible = false; + _SelectSlides[_SelectSlideOptionsAudioMode].Visible = false; _SelectSlides[_SelectSlideOptionsPlaylistAdd].Visible = false; _SelectSlides[_SelectSlideOptionsPlaylistOpen].Visible = false; _SelectSlides[_SelectSlideOptionsNumMedleySongs].Visible = false; @@ -1397,6 +1408,22 @@ namespace Vocaluxe.Screens //Set SelectSlide-Selection to last selected game-mode if possible _SelectSlides[_SelectSlideOptionsMode].SelectedTag = (int)lastMode; + + _SelectSlides[_SelectSlideOptionsAudioMode].Clear(); + CSong currentSong = CSongs.VisibleSongs[_SongMenu.GetPreviewSongNr()]; + if (currentSong.HasInstrumental()) + { + _SelectSlides[_SelectSlideOptionsAudioMode].AddValue("TR_AUDIOMODE_NORMAL"); + _SelectSlides[_SelectSlideOptionsAudioMode].AddValue("TR_AUDIOMODE_INSTRUMENTAL"); + _SelectSlides[_SelectSlideOptionsAudioMode].AddValue("TR_AUDIOMODE_KARAOKE"); + _SelectSlides[_SelectSlideOptionsAudioMode].Visible = true; + } + else + { + _SelectSlides[_SelectSlideOptionsAudioMode].Visible = false; + } + _SelectSlides[_SelectSlideOptionsAudioMode].Selection = (int)_AudioMode; + _SelectSlides[_SelectSlideOptionsMode].Visible = true; _SelectSlides[_SelectSlideOptionsPlaylistAdd].Visible = true; _Buttons[_ButtonOptionsSing].Visible = true; @@ -1404,6 +1431,7 @@ namespace Vocaluxe.Screens _Buttons[_ButtonOptionsHighscore].Visible = true; _SelectElement(_Buttons[_ButtonOptionsSing]); _SetSelectSlidePlaylistToCurrentPlaylist(); + } private void _ShowSongOptionsGeneral() diff --git a/VocaluxeLib/Enums.cs b/VocaluxeLib/Enums.cs index 018b3d68..70f2d82d 100644 --- a/VocaluxeLib/Enums.cs +++ b/VocaluxeLib/Enums.cs @@ -1,4 +1,4 @@ -#region license +#region license // This file is part of Vocaluxe. // // Vocaluxe is free software: you can redistribute it and/or modify @@ -364,6 +364,13 @@ namespace VocaluxeLib // ReSharper restore InconsistentNaming } + public enum EAudioMode + { + TR_AUDIOMODE_NORMAL, + TR_AUDIOMODE_INSTRUMENTAL, + TR_AUDIOMODE_KARAOKE + } + public enum ENoteType { Normal, diff --git a/VocaluxeLib/Songs/CSong.cs b/VocaluxeLib/Songs/CSong.cs index 93048cc2..1c49c13b 100644 --- a/VocaluxeLib/Songs/CSong.cs +++ b/VocaluxeLib/Songs/CSong.cs @@ -329,6 +329,11 @@ namespace VocaluxeLib.Songs return Path.Combine(Folder, InstrumentalFileName); } + public bool HasInstrumental() + { + return !string.IsNullOrEmpty(InstrumentalFileName); + } + public string GetVocals() { return Path.Combine(Folder, VocalsFileName);