Skip to content

Commit

Permalink
Reduce error logging when we can't find questScheduleIds known to be …
Browse files Browse the repository at this point in the history
…associated with pcap world manage quests.
  • Loading branch information
RyanYappert committed Dec 19, 2024
1 parent 9303036 commit 2a959ed
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion Arrowgene.Ddon.GameServer/Characters/QuestManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,15 @@ private QuestManager()
private static Dictionary<uint, HashSet<uint>> gTutorialQuests = new Dictionary<uint, HashSet<uint>>();
private static Dictionary<QuestAreaId, HashSet<QuestId>> gWorldQuests = new Dictionary<QuestAreaId, HashSet<QuestId>>();

/// <summary>
/// QuestScheduleIds that are requested as part of World Manage Quests from pcaps.
/// We know they can't be found, so don't audibly complain about them.
/// </summary>
private static readonly HashSet<uint> KnownBadQuestScheduleIds = new HashSet<uint>()
{
25077, 43645, 43646, 47734, 47736, 47737, 47738, 47739, 49692, 77644, 151381, 208640, 233576, 259411, 259412, 287378, 315624
};

public static void LoadQuests(DdonGameServer server)
{
var assetRepository = server.AssetRepository;
Expand Down Expand Up @@ -125,7 +134,11 @@ public static Quest GetQuestByScheduleId(uint questScheduleId)
{
if (!gQuests.ContainsKey(questScheduleId))
{
Logger.Error($"GetQuestByScheduleId: Invalid questScheduleId {questScheduleId}");
if (!KnownBadQuestScheduleIds.Contains(questScheduleId))
{
Logger.Error($"GetQuestByScheduleId: Invalid questScheduleId {questScheduleId}");
}

return null;
}

Expand Down

0 comments on commit 2a959ed

Please sign in to comment.