mirror of
https://github.com/All-Of-Us-Mods/MiraAPI.git
synced 2026-10-20 01:46:15 +00:00
attempt to improve gc behavior
This commit is contained in:
1 parent
0a0ad74419
commit
1b40b1c5e4
1 file changed
+4
-2
@@ -419,6 +419,8 @@ internal static class GameSettingMenuPatches
|
|||||||
_customTwoButton!.transform.localPosition = _customTwoBtnOgPos;
|
_customTwoButton!.transform.localPosition = _customTwoBtnOgPos;
|
||||||
menu.RoleSettingsButton.transform.localPosition = _roleBtnOgPos;
|
menu.RoleSettingsButton.transform.localPosition = _roleBtnOgPos;
|
||||||
|
|
||||||
|
CleanupTab(settings, roles);
|
||||||
|
|
||||||
if (SelectedModIdx != 0)
|
if (SelectedModIdx != 0)
|
||||||
{
|
{
|
||||||
_customOneButton.buttonText.text = SelectedMod!.MiraPlugin.CustomOptionMenuNameOne;
|
_customOneButton.buttonText.text = SelectedMod!.MiraPlugin.CustomOptionMenuNameOne;
|
||||||
@@ -560,8 +562,6 @@ internal static class GameSettingMenuPatches
|
|||||||
{
|
{
|
||||||
menu.ChangeTab(0, false);
|
menu.ChangeTab(0, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
CleanupTab(settings, roles);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void ClearOptions(Il2CppSystem.Collections.Generic.List<OptionBehaviour> options)
|
private static void ClearOptions(Il2CppSystem.Collections.Generic.List<OptionBehaviour> options)
|
||||||
@@ -606,6 +606,8 @@ internal static class GameSettingMenuPatches
|
|||||||
CleanupSettings(_customTwoTab, MenuCategory.CustomTwo);
|
CleanupSettings(_customTwoTab, MenuCategory.CustomTwo);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Utilities.Extensions.ClearGarbageCollector();
|
||||||
|
|
||||||
void CleanupRoleSettings(RolesSettingsMenu rolesMenu)
|
void CleanupRoleSettings(RolesSettingsMenu rolesMenu)
|
||||||
{
|
{
|
||||||
if (rolesMenu.advancedSettingChildren != null)
|
if (rolesMenu.advancedSettingChildren != null)
|
||||||
|
|||||||
Reference in new issue
Block a user