Prechádzať zdrojové kódy

Update version.
Bind to SongLoader songsLoaded event.
Fetch proper difficulty controller from BeatSaber.
Mostly fix extra stats display.

Stephen Damm 6 rokov pred
rodič
commit
3b1c24b8a8

+ 1 - 1
SongBrowserPlugin/Plugin.cs

@@ -14,7 +14,7 @@ namespace SongBrowserPlugin
 {
     public class Plugin : IPlugin
     {
-        public const string VERSION_NUMBER = "3.0.0";
+        public const string VERSION_NUMBER = "3.0.1";
 
         public string Name
         {

+ 3 - 3
SongBrowserPlugin/Properties/AssemblyInfo.cs

@@ -9,7 +9,7 @@ using System.Runtime.InteropServices;
 [assembly: AssemblyConfiguration("")]
 [assembly: AssemblyCompany("")]
 [assembly: AssemblyProduct("SongBrowserPlugin")]
-[assembly: AssemblyCopyright("Copyright ©  2018")]
+[assembly: AssemblyCopyright("Copyright ©  2019")]
 [assembly: AssemblyTrademark("")]
 [assembly: AssemblyCulture("")]
 
@@ -31,5 +31,5 @@ using System.Runtime.InteropServices;
 // You can specify all the values or you can default the Build and Revision Numbers 
 // by using the '*' as shown below:
 // [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("3.0.0")]
-[assembly: AssemblyFileVersion("3.0.0")]
+[assembly: AssemblyVersion("3.0.1")]
+[assembly: AssemblyFileVersion("3.0.1")]

+ 4 - 3
SongBrowserPlugin/SongBrowserApplication.cs

@@ -68,14 +68,14 @@ namespace SongBrowserPlugin
 
             StartCoroutine(ScrappedData.Instance.DownloadScrappedData((List<ScrappedSong> songs) => { }));
 
-            /*if (SongLoaderPlugin.SongLoader.AreSongsLoaded)
+            if (SongLoaderPlugin.SongLoader.AreSongsLoaded)
             {
                 OnSongLoaderLoadedSongs(null, SongLoader.CustomLevels);
             }
             else
             {
                 SongLoader.SongsLoadedEvent += OnSongLoaderLoadedSongs;
-            }*/
+            }
         }
 
         /// <summary>
@@ -88,7 +88,8 @@ namespace SongBrowserPlugin
             Logger.Trace("OnSongLoaderLoadedSongs-SongBrowserApplication()");
             try
             {
-                _songBrowserUI.UpdateSongList();
+                //_songBrowserUI.UpdateSongList();
+                _songBrowserUI.Model.UpdateScoreSaberDataMapping();
             }
             catch (Exception e)
             {

+ 1 - 1
SongBrowserPlugin/UI/Browser/SongBrowserUI.cs

@@ -205,7 +205,7 @@ namespace SongBrowserPlugin.UI
 
                 //if (_levelDifficultyViewController == null)
                 {
-                    _levelDifficultyViewController = Resources.FindObjectsOfTypeAll<BeatmapDifficultySegmentedControlController>().First();
+                    _levelDifficultyViewController = _standardLevelDetailView.GetPrivateField<BeatmapDifficultySegmentedControlController>("_beatmapDifficultySegmentedControlController");
                     Logger.Debug("Acquired BeatmapDifficultySegmentedControlController [{0}]", _levelDifficultyViewController.GetInstanceID());
                 }