diff options
| author | Vincent-Michael <Vincent_Michael@gmx.de> | 2014-04-06 01:25:09 +0200 |
|---|---|---|
| committer | Vincent-Michael <Vincent_Michael@gmx.de> | 2014-04-06 01:25:59 +0200 |
| commit | 19751f36f61c5da0d4b120b6a6c79d5016e3c240 (patch) | |
| tree | 9ba9c48b5214212f1252e581f7c1e74636496467 /src/server/game/Maps/Map.cpp | |
| parent | 4043680a5e5fb6a20966412dab168516e73c8ada (diff) | |
| parent | 98a9a088bf8cb05715e7fe186f241476691bbfee (diff) | |
Merge branch 'master' of github.com:TrinityCore/TrinityCore into 4.3.4
Diffstat (limited to 'src/server/game/Maps/Map.cpp')
| -rw-r--r-- | src/server/game/Maps/Map.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/server/game/Maps/Map.cpp b/src/server/game/Maps/Map.cpp index 43504bfad58..0110917487c 100644 --- a/src/server/game/Maps/Map.cpp +++ b/src/server/game/Maps/Map.cpp @@ -3482,13 +3482,12 @@ void Map::SetZoneMusic(uint32 zoneId, uint32 musicId) Map::PlayerList const& players = GetPlayers(); if (!players.isEmpty()) { - WorldPacket data(SMSG_PLAY_MUSIC, 4); - data << uint32(musicId); - for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr) if (Player* player = itr->GetSource()) if (player->GetZoneId() == zoneId) { + WorldPacket data(SMSG_PLAY_MUSIC, 4); + data << uint32(musicId); data << uint64(player->GetGUID()); player->SendDirectMessage(&data); } |
