Originally Posted by thebdc
I'm the author of the Compact Missions addon linked above, and that took me some time to figure out, too. So here's how it works:
- Get all completed missions with C_Garrison.GetCompleteMissions(). That returns a table of objects.
- For each entry in the table you have to call C_Garrison.MarkMissionComplete, with the missionID member of the object as the only parameter
- A event "GARRISON_MISSION_COMPLETE_RESPONSE" will be fired, which you have to handle. The only argument that comes with the event is the mission id
- When handling the above event, you have to call C_Garrison.CanOpenMissionChest, with the mission id as the only parameter. It returns true if the bonus chest can be opened
- If you can open the bonus chest you have to call C_Garrison.MissionBonusRoll, again with the mission id as the only parameter. That will fire the "GARRISON_MISSION_BONUS_ROLL_COMPLETE" event. You don't have to do anything with that one
|
I figured as much last night and got a few tests done. There are a few hiccups here and there which requires the code to be run multiple times to get everything done.