View Single Post
11-22-14, 05:11 AM   #8
SDPhantom
A Pyroguard Emberseer
 
SDPhantom's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 2,326
I ended up going with a two way approach. When GARRISON_MISSION_NPC_OPENED fires, I run a scanner that reruns itself every half second until there are no completed quests. I also have GARRISON_MISSION_FINISHED directly call C_Garrison.MarkMissionComplete() using the passed mission id and trigger a delayed scan to make sure everything was caught. I handle looting with GARRISON_MISSION_COMPLETE_RESPONSE checking C_Garrison.CanOpenMissionChest() and running C_Garrison.MissionBonusRoll() if true.



Note: GARRISON_MISSION_COMPLETE_RESPONSE should fire in response to C_Garrison.MarkMissionComplete() with info on whether the mission succeeded or not. It isn't reliable right now as it only seems to fire on successful missions.
__________________
WoWInterface AddOns
"All I want is a pretty girl, a decent meal, and the right to shoot lightning at fools."
-Anders (Dragon Age: Origins - Awakening)
  Reply With Quote