|
1234567891011121314151617181920212223242526 |
- using System;
- using System.Reflection;
-
- using RobocraftX.CR.MainGame;
- using RobocraftX.StateSync;
-
- using HarmonyLib;
-
- namespace GamecraftModdingAPI.App
- {
- [HarmonyPatch]
- class StateSyncRegPatch
- {
- public static void Postfix(StateSyncRegistrationHelper stateSyncReg)
- {
- // register sim/build events engines
- Game.InitDeterministic(stateSyncReg);
- }
-
- [HarmonyTargetMethod]
- public static MethodBase Target()
- {
- return AccessTools.Method(typeof(MainGameCompositionRoot), "DeterministicCompose").MakeGenericMethod(typeof(object));
- }
- }
- }
|