This commit is contained in:
Lachlan Leone
2024-04-01 08:12:01 +11:00
parent 581420da87
commit 35d3fec3de
34 changed files with 336 additions and 448 deletions
+17
View File
@@ -0,0 +1,17 @@
using HarmonyLib;
using Kitchen;
using KitchenLib.Utils;
using System.Reflection;
namespace MMOKitchen.Patches
{
[HarmonyPatch(typeof(PlayerManager), "GetLeastUnusedIndex")]
public class PlayerManagerPatch
{
static void Prefix(PlayerManager __instance)
{
FieldInfo info = ReflectionUtils.GetField<PlayerManager>("MaxPlayers");
info.SetValue(__instance, Mod.MaxPlayers);
}
}
}