2023-06-09 20:44:28 -07:00
|
|
|
|
using HarmonyLib;
|
|
|
|
|
|
2023-06-09 20:50:16 -07:00
|
|
|
|
namespace SteamRerouter.ModSide;
|
2023-06-09 20:44:28 -07:00
|
|
|
|
|
2023-06-09 22:47:31 -07:00
|
|
|
|
[HarmonyPatch]
|
2023-06-09 20:44:28 -07:00
|
|
|
|
public static class Patches
|
|
|
|
|
{
|
2023-06-09 22:47:31 -07:00
|
|
|
|
[HarmonyPrefix]
|
|
|
|
|
[HarmonyPatch(typeof(SteamEntitlementRetriever), nameof(SteamEntitlementRetriever.GetOwnershipStatus))]
|
|
|
|
|
private static bool SteamEntitlementRetriever_GetOwnershipStatus(out EntitlementsManager.AsyncOwnershipStatus __result)
|
2023-06-09 20:44:28 -07:00
|
|
|
|
{
|
2023-06-09 22:50:09 -07:00
|
|
|
|
__result = IpcServer.SteamEntitlementRetriever_GetOwnershipStatus();
|
2023-06-09 22:47:31 -07:00
|
|
|
|
return false;
|
2023-06-09 20:44:28 -07:00
|
|
|
|
}
|
|
|
|
|
|
2023-06-09 22:47:31 -07:00
|
|
|
|
[HarmonyPrefix]
|
|
|
|
|
[HarmonyPatch(typeof(Achievements), nameof(Achievements.Earn))]
|
|
|
|
|
private static bool Achievements_Earn(Achievements.Type type)
|
2023-06-09 20:44:28 -07:00
|
|
|
|
{
|
2023-06-09 22:50:09 -07:00
|
|
|
|
IpcServer.Achievements_Earn(type);
|
2023-06-09 22:47:31 -07:00
|
|
|
|
return false;
|
2023-06-09 20:44:28 -07:00
|
|
|
|
}
|
2023-06-09 22:47:31 -07:00
|
|
|
|
}
|