2024-07-05 00:13:40 +01:00
|
|
|
|
using System.Reflection;
|
|
|
|
|
using EFT.UI.Matchmaker;
|
|
|
|
|
using HarmonyLib;
|
|
|
|
|
using SPT.Reflection.Patching;
|
|
|
|
|
|
|
|
|
|
namespace SPT.SinglePlayer.Patches.MainMenu
|
|
|
|
|
{
|
|
|
|
|
public class DisableMatchmakerPlayerPreviewButtonsPatch : ModulePatch
|
|
|
|
|
{
|
|
|
|
|
protected override MethodBase GetTargetMethod()
|
|
|
|
|
{
|
|
|
|
|
return AccessTools.Method(typeof(MatchMakerPlayerPreview), nameof(MatchMakerPlayerPreview.Show));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[PatchPrefix]
|
2024-08-02 16:57:59 +01:00
|
|
|
|
public static void PatchPrefix(ref GClass3114 contextInteractions)
|
2024-07-05 00:13:40 +01:00
|
|
|
|
{
|
|
|
|
|
// clear with a null to stop "looking for group/create group" buttons
|
2024-08-28 12:52:54 +01:00
|
|
|
|
// they handle nulls so don't worry
|
2024-07-05 00:13:40 +01:00
|
|
|
|
contextInteractions = null;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|