Пример #1
0
        /// <summary>
        ///     Sets the SortStrings of the songpointers to the actual category names
        /// </summary>
        private static void _AdjustCategoryNames()
        {
            ESongSorting sorting = CSongs.Sorter.SongSorting;

            switch (sorting)
            {
            case ESongSorting.TR_CONFIG_DECADE:
                foreach (CSongPointer songPointer in CSongs.Sorter.SortedSongs)
                {
                    string year = songPointer.SortString;
                    if (year != "")
                    {
                        year = year.Substring(0, 3);
                        songPointer.SortString = year + "0 - " + year + "9";
                    }
                }
                break;

            case ESongSorting.TR_CONFIG_TITLE_LETTER:
            case ESongSorting.TR_CONFIG_ARTIST_LETTER:
                foreach (CSongPointer songPointer in CSongs.Sorter.SortedSongs)
                {
                    songPointer.SortString = (songPointer.SortString.Length == 0 || !Char.IsLetter(songPointer.SortString, 0)) ? "#" : songPointer.SortString[0].ToString();
                }
                break;

            case ESongSorting.TR_CONFIG_DATEADDED:
                foreach (CSongPointer songPointer in CSongs.Sorter.SortedSongs)
                {
                    songPointer.SortString = CSongs.GetSong(songPointer.SongID).DateAdded.ToString("dd/MM/yyyy");
                }
                break;
            }
        }
Пример #2
0
 public static void StopPreview()
 {
     if (!IsPlayingPreview)
     {
         return;
     }
     Stop();
     _CurPlayer = _BGPlayer;
     if (_MusicSource != EBackgroundMusicSource.TR_CONFIG_NO_OWN_MUSIC)
     {
         _CurPlayer.Load(CSongs.GetSong(_PreviewPlayer.SongID));
         _CurPlayer.Position = _PreviewPlayer.Position;
     }
     CSound.SetGlobalVolume(CConfig.BackgroundMusicVolume);
 }
Пример #3
0
 public static void SetNormalGameMode()
 {
     CSongs.ResetPartySongSung();
     CurrentPartyModeID = -1;
 }
Пример #4
0
 public void PrevCategory()
 {
     CSongs.PrevCategory();
 }
Пример #5
0
 public void NextCategory()
 {
     CSongs.NextCategory();
 }
Пример #6
0
 public void SortSongs(ESongSorting sorting, EOffOn tabs, EOffOn ignoreArticles, String searchString, EDuetOptions duetOptions, int playlistID)
 {
     CSongs.Sort(sorting, tabs, ignoreArticles, searchString, duetOptions, playlistID);
 }
Пример #7
0
 public void ResetSongSung(int catIndex)
 {
     CSongs.ResetPartySongSung(catIndex);
 }
Пример #8
0
 public void ResetSongSung()
 {
     CSongs.ResetPartySongSung();
 }
Пример #9
0
 public void AddPartySongSung(int songID)
 {
     CSongs.AddPartySongSung(songID);
 }
Пример #10
0
 public CCategory GetCategory(int index)
 {
     return(CSongs.GetCategoryByIndex(index));
 }
Пример #11
0
 public CSong GetSongByID(int songID)
 {
     return(CSongs.GetSong(songID));
 }
Пример #12
0
 public CSong GetVisibleSong(int visibleIndex)
 {
     return(CSongs.GetVisibleSongByIndex(visibleIndex));
 }
Пример #13
0
 public void UpdateRandomSongList()
 {
     CSongs.UpdateRandomSongList();
 }
Пример #14
0
 public int GetNumSongsNotSungInCategory(int categoryIndex)
 {
     return(CSongs.GetNumSongsNotSungInCategory(categoryIndex));
 }