internal static void CompleteQuest(ulong parNpcGuid, int parQuestId)
 {
     if (!ObjectManager.Instance.IsIngame)
     {
         return;
     }
     if (CompleteQuestFunction == null)
     {
         CompleteQuestFunction = Memory.Reader.RegisterDelegate <AcceptQuestDelegate>(funcs.CompleteQuest);
     }
     MainThread.Instance.Invoke(() => CompleteQuestFunction(ref parNpcGuid, parQuestId));
 }
Beispiel #2
0
        /// <summary>
        /// Adds an action to run when a player accepts a quest.
        /// </summary>
        /// <param name="action">The action to run when a player accepts a quest.</param>
        /// <returns>A QuestBuilder with the configured options.</returns>
        public QuestBuilder OnAcceptAction(AcceptQuestDelegate action)
        {
            _activeQuest.OnAcceptActions.Add(action);

            return(this);
        }