- SignalR handshake fix

- Self-hosted PhotonSocketServer support
- Split photon and hile event patch
- Deprecated amplitude redirect patch
This commit is contained in:
2025-04-13 02:11:08 -04:00
parent 155dda33b9
commit 8d1bac8201
13 changed files with 304 additions and 99 deletions

View File

@@ -1,11 +1,34 @@
using System.Collections.Generic;
using System.Reflection;
using System.Reflection;
using HarmonyLib;
using Il2CppSystem;
using UnityEngine;
namespace undead_universal_patch_il2cpp.Patches
{
[HarmonyPatch]
public class ConnectToRecNetPatchEvent
{
static readonly string TargetTypeName = "RecNet.Core";
static readonly string TargetMethodName = "ConnectToRecNet";
static readonly string Description = "Hile Patch event method"; // It's convenient. Could patch at a different time. But this part was easy.
static readonly MethodInfo connectMethod = AccessTools.Method(AccessTools.TypeByName(TargetTypeName), TargetMethodName);
static bool Prepare()
{
if (connectMethod == null)
{
Plugin.Log.LogWarning($"'{Description}' disabled. The method for this patch was not found.");
return false;
}
Plugin.Log.LogInfo($"'{Description}' succeeded validation.");
return true;
}
static MethodBase TargetMethod() => connectMethod;
static void Prefix()
{
if (GenericConfig.HilePatch.Value) HilePatch.Patch();
}
}
public static class HilePatch
{
public static void Patch()