mirror of
https://github.com/mangosfour/server.git
synced 2025-12-12 10:37:03 +00:00
[c12543] Fix crash when unit don't have visible auras
This commit is contained in:
parent
cfa0787a5f
commit
461f81a06a
2 changed files with 5 additions and 2 deletions
|
|
@ -20699,10 +20699,13 @@ void Player::learnSkillRewardedSpells(uint32 skill_id, uint32 skill_value)
|
||||||
|
|
||||||
void Player::SendAurasForTarget(Unit* target)
|
void Player::SendAurasForTarget(Unit* target)
|
||||||
{
|
{
|
||||||
|
Unit::VisibleAuraMap const& visibleAuras = target->GetVisibleAuras();
|
||||||
|
if (visibleAuras.empty())
|
||||||
|
return;
|
||||||
|
|
||||||
WorldPacket data(SMSG_AURA_UPDATE_ALL);
|
WorldPacket data(SMSG_AURA_UPDATE_ALL);
|
||||||
data << target->GetPackGUID();
|
data << target->GetPackGUID();
|
||||||
|
|
||||||
Unit::VisibleAuraMap const& visibleAuras = target->GetVisibleAuras();
|
|
||||||
for (Unit::VisibleAuraMap::const_iterator itr = visibleAuras.begin(); itr != visibleAuras.end(); ++itr)
|
for (Unit::VisibleAuraMap::const_iterator itr = visibleAuras.begin(); itr != visibleAuras.end(); ++itr)
|
||||||
itr->second->BuildUpdatePacket(data);
|
itr->second->BuildUpdatePacket(data);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "12542"
|
#define REVISION_NR "12543"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue