Exemplo n.º 1
0
 public static bool Prefix(GameAchievements.Id id)
 {
     try
     {
         if (typeof(GameAchievements).GetMethod("GetPlatformId", BindingFlags.NonPublic | BindingFlags.Static).Invoke(null, new object[] { id }) is string platformId)
         {
             PlatformUtils.main.GetServices().UnlockAchievement(platformId);
             Logger.Log($"[{QMod.assembly}] Force unlocked achievement {platformId}!", QMod.assembly);
         }
     }
     catch (Exception e)
     {
         Logger.Exception(e, LoggedWhen.InPatch, QMod.assembly);
     }
     return(false);
 }
Exemplo n.º 2
0
 internal static bool Prefix(GameAchievements.Id id)
 {
     PlatformUtils.main.GetServices().UnlockAchievement(id);
     return(false);
 }