mirror of
https://github.com/misternebula/quantum-space-buddies.git
synced 2025-01-18 13:23:05 +00:00
24 lines
565 B
C#
24 lines
565 B
C#
using HarmonyLib;
|
|
using QSB.Events;
|
|
using QSB.Patches;
|
|
|
|
namespace QSB.LogSync.Patches
|
|
{
|
|
[HarmonyPatch]
|
|
public class LogPatches : QSBPatch
|
|
{
|
|
public override QSBPatchTypes Type => QSBPatchTypes.OnClientConnect;
|
|
|
|
[HarmonyPostfix]
|
|
[HarmonyPatch(typeof(ShipLogManager), nameof(ShipLogManager.RevealFact))]
|
|
public static void ShipLogManager_RevealFact(string id, bool saveGame, bool showNotification, bool __result)
|
|
{
|
|
if (!__result)
|
|
{
|
|
return;
|
|
}
|
|
|
|
QSBEventManager.FireEvent(EventNames.QSBRevealFact, id, saveGame, showNotification);
|
|
}
|
|
}
|
|
} |