mirror of
https://github.com/sp-tarkov/modules.git
synced 2025-02-12 20:50:44 -05:00
Adds Patch to remove use BSG servers for matchmaking (needs looking at when we get more data)
This commit is contained in:
parent
d071b202f2
commit
1277e10381
@ -0,0 +1,27 @@
|
|||||||
|
using System.Reflection;
|
||||||
|
using EFT.UI;
|
||||||
|
using HarmonyLib;
|
||||||
|
using SPT.Reflection.Patching;
|
||||||
|
|
||||||
|
namespace SPT.SinglePlayer.Patches.MainMenu
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Removes BSG's checkmark to use BSG servers instead of local hosted
|
||||||
|
/// Also Sets checkmark to false.if checkmark is somehow enabled it will default to false (local raid only)
|
||||||
|
/// </summary>
|
||||||
|
public class DisableUseBSGServersCheckbox : ModulePatch
|
||||||
|
{
|
||||||
|
protected override MethodBase GetTargetMethod()
|
||||||
|
{
|
||||||
|
return AccessTools.Method(typeof(LocationInfoPanel), nameof(LocationInfoPanel.method_1));
|
||||||
|
}
|
||||||
|
|
||||||
|
[PatchPostfix]
|
||||||
|
public static void PatchPostfix(ref UpdatableToggle ____onlineModeToggle)
|
||||||
|
{
|
||||||
|
|
||||||
|
____onlineModeToggle.isOn = false;
|
||||||
|
____onlineModeToggle.transform.parent.gameObject.SetActive(false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -23,6 +23,7 @@
|
|||||||
<Reference Include="UnityEngine.AudioModule" HintPath="..\Shared\Managed\UnityEngine.AudioModule.dll" Private="False" />
|
<Reference Include="UnityEngine.AudioModule" HintPath="..\Shared\Managed\UnityEngine.AudioModule.dll" Private="False" />
|
||||||
<Reference Include="UnityEngine.CoreModule" HintPath="..\Shared\Managed\UnityEngine.CoreModule.dll" Private="False" />
|
<Reference Include="UnityEngine.CoreModule" HintPath="..\Shared\Managed\UnityEngine.CoreModule.dll" Private="False" />
|
||||||
<Reference Include="Sirenix.Serialization" HintPath="..\Shared\Managed\Sirenix.Serialization.dll" Private="False" />
|
<Reference Include="Sirenix.Serialization" HintPath="..\Shared\Managed\Sirenix.Serialization.dll" Private="False" />
|
||||||
|
<Reference Include="UnityEngine.UI" HintPath="..\Shared\Managed\UnityEngine.UI.dll" Private="False" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
@ -71,6 +71,7 @@ namespace SPT.SinglePlayer
|
|||||||
new DisableDevMaskCheckPatch().Enable();
|
new DisableDevMaskCheckPatch().Enable();
|
||||||
new RemoveStopwatchAllocationsEveryBotFramePatch().Enable();
|
new RemoveStopwatchAllocationsEveryBotFramePatch().Enable();
|
||||||
new RemoveStopwatchAllocationsEveryCoverPointFramePatch().Enable();
|
new RemoveStopwatchAllocationsEveryCoverPointFramePatch().Enable();
|
||||||
|
new DisableUseBSGServersCheckbox().Enable();
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user