//Tracking the play history SetTopScore function
        public static void SetTopScore(SongInfoTopScoreItem item)
        {
            SongInfoTopScoreItem topScoreItem = item;

            //Get percentage
            float percentage = GetHighScorePercentage(selectedSong);

            //Make pretty-ish strings
            string scoreString      = "<size=" + historyTopScoreSize + ">" + String.Format("{0:n0}", HighScoreRecords.GetHighScore(selectedSong).score).Replace(",", " ") + "</size>";
            string percentageString = "<size=" + historyTopPercentSize + "> (" + String.Format("{0:0.00}", percentage) + "%)</size>";

            //Update label
            topScoreItem.score.text = scoreString + percentageString;
        }
Example #2
0
 private static void Postfix(SongInfoPanel __instance, ref SongInfoTopScoreItem item)
 {
     AudicaMod.SetTopScore(item);
 }