mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-23 07:40:14 +00:00
game: clear target auras when switching targets
setTarget() was not clearing targetAuras, leaving stale buff/debuff icons from the previous target visible on the buff bar until the server sent SMSG_AURA_UPDATE_ALL for the new target. Reset all slots to empty on target change so the display is immediately correct.
This commit is contained in:
parent
1e53369869
commit
ac0fe1bd61
1 changed files with 4 additions and 0 deletions
|
|
@ -8760,6 +8760,10 @@ void GameHandler::setTarget(uint64_t guid) {
|
|||
|
||||
targetGuid = guid;
|
||||
|
||||
// Clear stale aura data from the previous target so the buff bar shows
|
||||
// an empty state until the server sends SMSG_AURA_UPDATE_ALL for the new target.
|
||||
for (auto& slot : targetAuras) slot = AuraSlot{};
|
||||
|
||||
// Clear previous target's cast bar on target change
|
||||
// (the new target's cast state is naturally fetched from unitCastStates_ by GUID)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue