fix(Core/Player): Players are allowed to continue melee attacking on … (#6267)
- Closes #6248. - Closes #5734 - Closes chromiecraft/chromiecraft#795
This commit is contained in:
@@ -21113,9 +21113,6 @@ void Player::SendAutoRepeatCancel(Unit* target)
|
|||||||
WorldPacket data(SMSG_CANCEL_AUTO_REPEAT, target->GetPackGUID().size());
|
WorldPacket data(SMSG_CANCEL_AUTO_REPEAT, target->GetPackGUID().size());
|
||||||
data << target->GetPackGUID(); // may be it's target guid
|
data << target->GetPackGUID(); // may be it's target guid
|
||||||
SendMessageToSet(&data, true);
|
SendMessageToSet(&data, true);
|
||||||
|
|
||||||
// To properly cancel autoshot done by client
|
|
||||||
SendAttackSwingCancelAttack();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Player::SendExplorationExperience(uint32 Area, uint32 Experience)
|
void Player::SendExplorationExperience(uint32 Area, uint32 Experience)
|
||||||
|
|||||||
@@ -3376,9 +3376,10 @@ void Unit::_UpdateAutoRepeatSpell()
|
|||||||
static uint32 const HUNTER_AUTOSHOOT = 75;
|
static uint32 const HUNTER_AUTOSHOOT = 75;
|
||||||
|
|
||||||
// Check "realtime" interrupts
|
// Check "realtime" interrupts
|
||||||
if ((GetTypeId() == TYPEID_PLAYER && ToPlayer()->isMoving() && spellProto->Id != HUNTER_AUTOSHOOT) ||
|
if ((GetTypeId() == TYPEID_PLAYER && ToPlayer()->isMoving() && spellProto->Id != HUNTER_AUTOSHOOT) || IsNonMeleeSpellCast(false, false, true, spellProto->Id == HUNTER_AUTOSHOOT))
|
||||||
IsNonMeleeSpellCast(false, false, true, spellProto->Id == HUNTER_AUTOSHOOT))
|
|
||||||
{
|
{
|
||||||
|
// cancel wand shoot
|
||||||
|
if (spellProto->Id != HUNTER_AUTOSHOOT)
|
||||||
InterruptSpell(CURRENT_AUTOREPEAT_SPELL);
|
InterruptSpell(CURRENT_AUTOREPEAT_SPELL);
|
||||||
m_AutoRepeatFirstCast = true;
|
m_AutoRepeatFirstCast = true;
|
||||||
return;
|
return;
|
||||||
|
|||||||
Reference in New Issue
Block a user