From 45770592e52061fcbcaa34dde0af6b6dd19206a2 Mon Sep 17 00:00:00 2001 From: Laise Date: Fri, 2 Apr 2010 22:47:35 +0400 Subject: [PATCH] [9658] Remove SPELL_EFFECT_TITAN_GRIP flag at related spell remove. This let have correct state for flag at .unlearn related spell and etc. Not only at full talent reset. Signed-off-by: VladimirMangos --- src/game/Player.cpp | 20 +++++++++++--------- src/shared/revision_nr.h | 2 +- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/src/game/Player.cpp b/src/game/Player.cpp index 94f644598..db9ed39fa 100644 --- a/src/game/Player.cpp +++ b/src/game/Player.cpp @@ -3431,6 +3431,17 @@ void Player::removeSpell(uint32 spell_id, bool disabled, bool learn_low_rank, bo } } + if (m_canTitanGrip) + { + SpellEntry const *spellInfo = sSpellStore.LookupEntry(spell_id); + if (IsSpellHaveEffect(spellInfo, SPELL_EFFECT_TITAN_GRIP)) + { + m_canTitanGrip = false; + if(sWorld.getConfig(CONFIG_BOOL_OFFHAND_CHECK_AT_TALENTS_RESET)) + AutoUnequipOffhandIfNeed(); + } + } + // remove from spell book if not replaced by lesser rank if (!prev_activate && sendUpdate) { @@ -3700,15 +3711,6 @@ bool Player::resetTalents(bool no_cost) RemovePet(NULL,PET_SAVE_NOT_IN_SLOT, true); } */ - - - if(m_canTitanGrip) - { - m_canTitanGrip = false; - if(sWorld.getConfig(CONFIG_BOOL_OFFHAND_CHECK_AT_TALENTS_RESET)) - AutoUnequipOffhandIfNeed(); - } - return true; } diff --git a/src/shared/revision_nr.h b/src/shared/revision_nr.h index efc5bd2bc..deefa4b7a 100644 --- a/src/shared/revision_nr.h +++ b/src/shared/revision_nr.h @@ -1,4 +1,4 @@ #ifndef __REVISION_NR_H__ #define __REVISION_NR_H__ - #define REVISION_NR "9657" + #define REVISION_NR "9658" #endif // __REVISION_NR_H__ -- 2.11.4.GIT