mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-26 16:50:15 +00:00
fix: clear craft queue on spell failure and all cast reset paths
craftQueueSpellId_ and craftQueueRemaining_ were already cleared in cancelCast(), stopCasting(), and SMSG_CAST_RESULT failure, but were missing from five other cast-abort paths: - SMSG_SPELL_FAILURE (mid-cast interrupt): queue persisted after combat interruption, risking a ghost re-cast on the next SMSG_SPELL_GO - handleCastFailed() (SMSG_CAST_FAILED): queue persisted if the server rejected a craft before it started - Player login state reset: leftover queue from prior session survived into the new world session - Same-map resurrection (SMSG_NEW_WORLD): queue persisted through spirit-healer resurrection teleport - Regular world transfer (SMSG_NEW_WORLD): queue persisted across zone changes and dungeon portals
This commit is contained in:
parent
6be695078b
commit
57b44d2347
1 changed files with 10 additions and 0 deletions
|
|
@ -3355,6 +3355,8 @@ void GameHandler::handlePacket(network::Packet& packet) {
|
|||
castIsChannel = false;
|
||||
currentCastSpellId = 0;
|
||||
lastInteractedGoGuid_ = 0;
|
||||
craftQueueSpellId_ = 0;
|
||||
craftQueueRemaining_ = 0;
|
||||
queuedSpellId_ = 0;
|
||||
queuedSpellTarget_ = 0;
|
||||
if (auto* renderer = core::Application::getInstance().getRenderer()) {
|
||||
|
|
@ -9097,6 +9099,8 @@ void GameHandler::selectCharacter(uint64_t characterGuid) {
|
|||
lastInteractedGoGuid_ = 0;
|
||||
castTimeRemaining = 0.0f;
|
||||
castTimeTotal = 0.0f;
|
||||
craftQueueSpellId_ = 0;
|
||||
craftQueueRemaining_ = 0;
|
||||
queuedSpellId_ = 0;
|
||||
queuedSpellTarget_ = 0;
|
||||
playerDead_ = false;
|
||||
|
|
@ -18351,6 +18355,8 @@ void GameHandler::handleCastFailed(network::Packet& packet) {
|
|||
currentCastSpellId = 0;
|
||||
castTimeRemaining = 0.0f;
|
||||
lastInteractedGoGuid_ = 0;
|
||||
craftQueueSpellId_ = 0;
|
||||
craftQueueRemaining_ = 0;
|
||||
queuedSpellId_ = 0;
|
||||
queuedSpellTarget_ = 0;
|
||||
|
||||
|
|
@ -22061,6 +22067,8 @@ void GameHandler::handleNewWorld(network::Packet& packet) {
|
|||
castIsChannel = false;
|
||||
currentCastSpellId = 0;
|
||||
castTimeRemaining = 0.0f;
|
||||
craftQueueSpellId_ = 0;
|
||||
craftQueueRemaining_ = 0;
|
||||
queuedSpellId_ = 0;
|
||||
queuedSpellTarget_ = 0;
|
||||
|
||||
|
|
@ -22121,6 +22129,8 @@ void GameHandler::handleNewWorld(network::Packet& packet) {
|
|||
pendingGameObjectInteractGuid_ = 0;
|
||||
lastInteractedGoGuid_ = 0;
|
||||
castTimeRemaining = 0.0f;
|
||||
craftQueueSpellId_ = 0;
|
||||
craftQueueRemaining_ = 0;
|
||||
queuedSpellId_ = 0;
|
||||
queuedSpellTarget_ = 0;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue