Scripts/Quests: Implemented new quest scripting hook, OnQuestAcknowledgeAutoAccept, used when player closes quest frame after viewing details of autoaccept quests

Port From (https://github.com/TrinityCore/TrinityCore/commit/f269f60d8a5f6b0982eb46dc583e2618c98931fb)
This commit is contained in:
hondacrx
2021-03-04 12:13:43 -05:00
parent 96b98cc4d3
commit 5b09d675dd
4 changed files with 35 additions and 0 deletions
+7
View File
@@ -1188,6 +1188,13 @@ namespace Game.Scripting
RunScript<QuestScript>(script => script.OnQuestStatusChange(player, quest, oldStatus, newStatus), quest.ScriptId);
}
public void OnQuestAcknowledgeAutoAccept(Player player, Quest quest)
{
Cypher.Assert(player);
Cypher.Assert(quest != null);
RunScript<QuestScript>(script => script.OnAcknowledgeAutoAccept(player, quest), quest.ScriptId);
}
public void OnQuestObjectiveChange(Player player, Quest quest, QuestObjective objective, int oldAmount, int newAmount)
{
Cypher.Assert(player);