From 7c8be51b9446e024e813b81a120240aeec8550a9 Mon Sep 17 00:00:00 2001 From: RealityMachina Date: Thu, 24 May 2018 20:48:20 -0400 Subject: [PATCH] Serialization and deserialization with metatrackers. --- PunchinOut/SaveGamePatcher.cs | 8 ++++---- PunchinOut/panicTracker.cs | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/PunchinOut/SaveGamePatcher.cs b/PunchinOut/SaveGamePatcher.cs index b4860cb..182b3e8 100644 --- a/PunchinOut/SaveGamePatcher.cs +++ b/PunchinOut/SaveGamePatcher.cs @@ -19,12 +19,12 @@ static void Postfix(GameInstanceSave __instance) } } - [HarmonyPatch(typeof(GameInstanceSave), "Load")] - public static class GameInstanceSave_Load_Patch + [HarmonyPatch(typeof(GameInstance), "Load")] + public static class GameInstance_Load_Patch { - static void Prefix(GameInstanceSave __instance) + static void Prefix(GameInstanceSave save) { - Holder.Resync(__instance.SaveTime); + Holder.Resync(save.SaveTime); } } } diff --git a/PunchinOut/panicTracker.cs b/PunchinOut/panicTracker.cs index bb99afd..99b031f 100644 --- a/PunchinOut/panicTracker.cs +++ b/PunchinOut/panicTracker.cs @@ -43,9 +43,9 @@ public PanicTracker(Mech mech) public class MetaTracker { - public List TrackedPilots { get; private set; } - public DateTime SaveGameTimeStamp { get; private set; } - public string SimGameGUID { get; private set; } + public List TrackedPilots { get; set; } + public DateTime SaveGameTimeStamp { get; set; } + public string SimGameGUID { get; set; } public MetaTracker() {