Merge remote branch 'origin/master' into 330

This commit is contained in:
tomrus88 2009-12-17 16:13:37 +03:00
commit eba214eb8a
15 changed files with 58 additions and 56 deletions

View file

@ -3187,7 +3187,7 @@ void Player::learnSpell(uint32 spell_id, bool dependent)
GetSession()->SendPacket(&data);
}
void Player::removeSpell(uint32 spell_id, bool disabled, bool learn_low_rank)
void Player::removeSpell(uint32 spell_id, bool disabled, bool learn_low_rank, bool sendUpdate)
{
PlayerSpellMap::iterator itr = m_spells.find(spell_id);
if (itr == m_spells.end())
@ -3366,7 +3366,7 @@ void Player::removeSpell(uint32 spell_id, bool disabled, bool learn_low_rank)
}
// remove from spell book if not replaced by lesser rank
if(!prev_activate)
if (!prev_activate && sendUpdate)
{
WorldPacket data(SMSG_REMOVED_SPELL, 4);
data << uint32(spell_id);
@ -21287,4 +21287,4 @@ void Player::SetHomebindToCurrentPos()
// update sql homebind
CharacterDatabase.PExecute("UPDATE character_homebind SET map = '%u', zone = '%u', position_x = '%f', position_y = '%f', position_z = '%f' WHERE guid = '%u'",
m_homebindMapId, m_homebindZoneId, m_homebindX, m_homebindY, m_homebindZ, GetGUIDLow());
}
}