Skip to content

Commit

Permalink
Fix collision errors when loading
Browse files Browse the repository at this point in the history
  • Loading branch information
misternebula committed Feb 5, 2022
1 parent e954782 commit 1783271
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
6 changes: 3 additions & 3 deletions QSB/Menus/MenuManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ private void OpenInfoPopup(string message, string okButtonText)
{
OneButtonInfoPopup.SetUpPopup(message, InputLibrary.menuConfirm, InputLibrary.cancel, new ScreenPrompt(okButtonText), null, true, false);

OWTime.Pause(OWTime.PauseType.System);
OWTime.Pause(OWTime.PauseType.Menu);
OWInput.ChangeInputMode(InputMode.Menu);

var pauseCommandListener = Locator.GetPauseCommandListener();
Expand All @@ -143,7 +143,7 @@ private void OpenInfoPopup(string message, string okButtonText, string cancelBut
{
TwoButtonInfoPopup.SetUpPopup(message, InputLibrary.menuConfirm, InputLibrary.cancel, new ScreenPrompt(okButtonText), new ScreenPrompt(cancelButtonText), true, true);

OWTime.Pause(OWTime.PauseType.System);
OWTime.Pause(OWTime.PauseType.Menu);
OWInput.ChangeInputMode(InputMode.Menu);

var pauseCommandListener = Locator.GetPauseCommandListener();
Expand All @@ -165,7 +165,7 @@ private void OnCloseInfoPopup()
_addedPauseLock = false;
}

OWTime.Unpause(OWTime.PauseType.System);
OWTime.Unpause(OWTime.PauseType.Menu);
OWInput.RestorePreviousInputs();

PopupOK?.SafeInvoke();
Expand Down
8 changes: 6 additions & 2 deletions QSB/TimeSync/Patches/TimePatches.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,14 @@ public static bool PlayerCameraEffectController_OnStartOfTimeLoop()
DebugLog.DebugWrite($"OnStartOfTimeLoop");
return false;
}

[HarmonyPrefix]
[HarmonyPatch(typeof(OWTime), nameof(OWTime.Pause))]
public static bool StopPausing()
=> false;
public static bool StopPausing(OWTime.PauseType pauseType)
=> pauseType
is OWTime.PauseType.Initializing
or OWTime.PauseType.Streaming
or OWTime.PauseType.Loading;

[HarmonyPrefix]
[HarmonyPatch(typeof(SubmitActionSkipToNextLoop), nameof(SubmitActionSkipToNextLoop.AdvanceToNewTimeLoop))]
Expand Down
2 changes: 1 addition & 1 deletion QSB/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"body": "- Disable *all* other mods. (Can heavily affect performance)\n- Make sure you are not running any other network-intensive applications.\n- Make sure you have forwarded/opened the correct ports. (See the GitHub readme.)"
},
"uniqueName": "Raicuparta.QuantumSpaceBuddies",
"version": "0.16.0",
"version": "0.16.1",
"owmlVersion": "2.3.1",
"dependencies": [ "_nebula.MenuFramework" ]
}

0 comments on commit 1783271

Please sign in to comment.