mirror of
https://github.com/MewoLab/AquaDX.git
synced 2026-02-11 13:17:27 +08:00
[F] Game crash after one track with new AIME with SkipToMusicSelection
This commit is contained in:
@@ -1,5 +1,9 @@
|
||||
using HarmonyLib;
|
||||
using MAI2.Util;
|
||||
using Manager;
|
||||
using Manager.UserDatas;
|
||||
using MelonLoader;
|
||||
using Monitor;
|
||||
using Process;
|
||||
using Process.Information;
|
||||
|
||||
@@ -22,5 +26,15 @@ namespace AquaMai.UX
|
||||
___container.processManager.ReleaseProcess(__instance);
|
||||
return false;
|
||||
}
|
||||
|
||||
[HarmonyPrefix]
|
||||
[HarmonyPatch(typeof(MapResultMonitor), "Initialize")]
|
||||
public static void MapResultMonitorPreInitialize(int monIndex)
|
||||
{
|
||||
var userData = Singleton<UserDataManager>.Instance.GetUserData(monIndex);
|
||||
var index = userData.MapList.FindIndex((UserMapData m) => m.ID == userData.Detail.SelectMapID);
|
||||
if (index >= 0) return;
|
||||
userData.MapList.Clear();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user