mirror of
https://github.com/MoltenMods/Unify.git
synced 2026-10-19 17:56:57 +00:00
Change regions after ServerManager.LoadServers instead of on game load
This commit is contained in:
1 parent
e26fbccdb9
commit
7c1e2533b2
3 files changed
+10
-3
No files matched your search
@@ -84,6 +84,15 @@ namespace Unify.Patches
|
||||
regionMenu.ChooseOption(newRegion);
|
||||
regionMenu.Close();
|
||||
}
|
||||
|
||||
[HarmonyPatch(typeof(ServerManager), nameof(ServerManager.LoadServers))]
|
||||
public static class PatchRegionMenuPatch
|
||||
{
|
||||
public static void Postfix()
|
||||
{
|
||||
Patch();
|
||||
}
|
||||
}
|
||||
|
||||
[HarmonyPatch(typeof(RegionMenu), nameof(RegionMenu.Open))]
|
||||
public static class DirectConnectButtonPatch
|
||||
|
||||
+1
-3
@@ -40,9 +40,7 @@ namespace Unify
|
||||
|
||||
ConfigFile = new ConfigFile(Path.Combine(Paths.ConfigPath, $"{UnifyPlugin.Id}.cfg"), true);
|
||||
// =====================================
|
||||
|
||||
RegionsPatch.Patch();
|
||||
|
||||
|
||||
// Unpatches the modded handshake, because Impostor is STILL not fully updated yet
|
||||
Harmony.Unpatch(typeof(UdpConnection).GetMethod("HandleSend"), HarmonyPatchType.Prefix,
|
||||
ReactorPlugin.Id);
|
||||
|
||||
Binary file not shown.
Reference in new issue
Block a user