mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-04-17 17:43:52 +00:00
fix: GO interaction casts canceled by any movement — quest credit lost
pendingGameObjectInteractGuid_ was always cleared to 0 right before the interaction, which defeated the cancel-protection guard in cancelCast(). Any positional movement (WASD, jump) during a GO interaction cast (e.g., "Opening" on a quest chest) sent CMSG_CANCEL_CAST to the server, aborting the interaction and preventing quest objective credit. Now sets pendingGameObjectInteractGuid_ to the GO guid so: 1. cancelCast() skips CMSG_CANCEL_CAST for GO-triggered casts 2. The cast-completion fallback can re-trigger loot after timer expires 3. isGameObjectInteractionCasting() returns true during GO casts
This commit is contained in:
parent
c1c28d4216
commit
6b5e924027
1 changed files with 8 additions and 2 deletions
|
|
@ -6114,8 +6114,14 @@ void GameHandler::interactWithGameObject(uint64_t guid) {
|
||||||
if (spellHandler_ && spellHandler_->casting_ && spellHandler_->currentCastSpellId_ != 0) return;
|
if (spellHandler_ && spellHandler_->casting_ && spellHandler_->currentCastSpellId_ != 0) return;
|
||||||
// Always clear melee intent before GO interactions.
|
// Always clear melee intent before GO interactions.
|
||||||
stopAutoAttack();
|
stopAutoAttack();
|
||||||
// Interact immediately; server drives any real cast/channel feedback.
|
// Set the pending GO guid so that:
|
||||||
pendingGameObjectInteractGuid_ = 0;
|
// 1. cancelCast() won't send CMSG_CANCEL_CAST for GO-triggered casts
|
||||||
|
// (e.g., "Opening" on a quest chest) — without this, any movement
|
||||||
|
// during the cast cancels it server-side and quest credit is lost.
|
||||||
|
// 2. The cast-completion fallback in update() can call
|
||||||
|
// performGameObjectInteractionNow after the cast timer expires.
|
||||||
|
// 3. isGameObjectInteractionCasting() returns true during GO casts.
|
||||||
|
pendingGameObjectInteractGuid_ = guid;
|
||||||
performGameObjectInteractionNow(guid);
|
performGameObjectInteractionNow(guid);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue