BG Queue Tracker

BG Queue Tracker

5.1k Downloads

Pauses not always detected

mcd8604 opened this issue ยท 0 comments

commented

Occasionally, exiting a BG is not detected and the queue statuses are not updated.

Cause: battleFieldIndex can change for queues
Explanation: queue indices 1 and 3 are 'queued' status and index 2 is 'active'. The player exits the battleground and index 2 is now 'none'. However, the server shifts the queue from index 3 to index 2 (index 3 becomes 'none' instead). When the UPDATE_BATTLEFIELD_STATUS event is triggered for index 2 as it ends, a subsequent call to GetBattlefieldStatus will yield the status for the recently moved queue and not the queue which had just completed.

Solution:

  • Call GetBattlefieldStatus for all queue indices for every UPDATE_BATTLEFIELD_STATUS event.
  • Locally cache the queue status, indexed by map name instead of queue index.
  • For each GetBattlefieldStatus call, check the previously stored status for that map name and determine if it is a queue start, update, or closure.