Fix out of date access modifiers

This commit is contained in:
NGnius (Graham) 2020-12-23 11:19:31 -05:00
parent 384f1b3092
commit e4a1c0c607

View file

@ -1,3 +1,4 @@
using System.Reflection;
using HarmonyLib;
using Svelto.DataStructures;
using Svelto.ECS;
@ -89,6 +90,8 @@ namespace CLre.API.Engines
internal static FasterList<FrontEndEnginePostBuild> afterBuildEngines = new FasterList<FrontEndEnginePostBuild>();
internal static MethodInfo addEngine = AccessTools.Method(typeof(FrontEnd.MainFrontEnd), "AddEngine");
[HarmonyPrefix]
public static void BeforeMethodCall(FrontEnd.MainFrontEnd __instance)
{
@ -96,7 +99,7 @@ namespace CLre.API.Engines
foreach (ICLreEngine e in beforeBuildEngines)
{
e.entityFactory = factory;
__instance.AddEngine(e);
addEngine.Invoke(__instance, new object[] {e}); // __instance.AddEngine(e);
}
}
@ -107,7 +110,7 @@ namespace CLre.API.Engines
foreach (ICLreEngine e in afterBuildEngines)
{
e.entityFactory = factory;
__instance.AddEngine(e);
addEngine.Invoke(__instance, new object[] {e}); // __instance.AddEngine(e);
}
}
}
@ -119,6 +122,8 @@ namespace CLre.API.Engines
internal static FasterList<FrontEndObsoleteEnginePostBuild> afterBuildEngines = new FasterList<FrontEndObsoleteEnginePostBuild>();
internal static MethodInfo addEngine = AccessTools.Method(typeof(FrontEnd.MainFrontEnd), "AddEngine");
[HarmonyPrefix]
public static void BeforeMethodCall(FrontEnd.MainFrontEnd __instance)
{
@ -126,7 +131,7 @@ namespace CLre.API.Engines
foreach (ICLreEngine e in beforeBuildEngines)
{
e.entityFactory = factory;
__instance.AddEngine(e);
addEngine.Invoke(__instance, new object[] {e}); // __instance.AddEngine(e);
}
}
@ -137,7 +142,7 @@ namespace CLre.API.Engines
foreach (ICLreEngine e in afterBuildEngines)
{
e.entityFactory = factory;
__instance.AddEngine(e);
addEngine.Invoke(__instance, new object[] {e}); // __instance.AddEngine(e);
}
}
}