Пример #1
0
 // Don't put the delivered items in the lost and found
 private static bool SpecialOrder_OnFail_prefix(ref SpecialOrder __instance)
 {
     try
     {
         if (__instance.questKey.Value != PIKAQUEST)
         {
             return(true);
         }
         foreach (OrderObjective objective in __instance.objectives)
         {
             objective.OnFail();
         }
         if (Game1.IsMasterGame)
         {
             __instance.HostHandleQuestEnd();
         }
         __instance.questState.Value = SpecialOrder.QuestState.Failed;
         return(false);
     }
     catch (Exception ex)
     {
         Log.Error($"RSV: Error prefixing SpecialOrder.OnFail:\n\n{ex}");
     }
     return(true);
 }