public override async Task <bool> StartTask() { var bounty = ZetaDia.Storage.Quests.Bounties .Where(c => c.Act == Act && c.Info.State != QuestState.Completed && !_blacklist.Contains(c.Quest)) .OrderByDescending(c => (int)c.Quest) .FirstOrDefault(); // Bounties completed in this Act. if (bounty == null) { return(true); } _bounty = BountyCoroutineFactory.GetBounty(bounty); if (_bounty == null) { Core.Logger.Error($"[RunBountySimple] Bounty is not supported ({QuestId}), ending tag."); _blacklist.Add(bounty.Quest); // Pick the next... return(await StartTask()); } _bounty.Reset(); return(false); }
public override async Task <bool> StartTask() { var bountyInfo = ZetaDia.Storage.Quests.Bounties.FirstOrDefault(b => (int)b.Quest == QuestId); if (bountyInfo == null) { Core.Logger.Error($"[RunBountyTag] Bounty is not available in this game."); return(true); } _bounty = BountyCoroutineFactory.GetBounty(bountyInfo); if (_bounty == null) { Core.Logger.Error($"[RunBountyTag] Bounty is not supported ({QuestId}), ending tag."); return(true); } _bounty.Reset(); return(false); }