static void Postfix(Thing __instance) { if (Multiplayer.game == null) { return; } ScribeUtil.sharedCrossRefs.Unregister(__instance); ThingsById.Unregister(__instance); }
static void Prefix(Map map) { if (Multiplayer.game == null) { return; } ScribeUtil.sharedCrossRefs.UnregisterAllFrom(map); ThingsById.UnregisterAllFrom(map); ScribeUtil.sharedCrossRefs.Unregister(map); }
static void Postfix(Thing __instance) { if (Multiplayer.game == null) { return; } if (__instance.def.HasThingIDNumber) { ScribeUtil.sharedCrossRefs.RegisterLoaded(__instance); ThingsById.Register(__instance); } }