Core/Packets: converted SMSG_PLAY_MUSIC to packet class and corrected packet structure
This commit is contained in:
1 parent
77f94a456c
commit
113202ea48
5 files changed
+31
-24
No files matched your search
@@ -2626,14 +2626,12 @@ void WorldObject::PlayDirectSound(uint32 sound_id, Player* target /*= nullptr*/)
|
||||
SendMessageToSet(packet.Write(), true);
|
||||
}
|
||||
|
||||
void WorldObject::PlayDirectMusic(uint32 music_id, Player* target /*= nullptr*/)
|
||||
void WorldObject::PlayDirectMusic(uint32 musicId, Player* target /*= nullptr*/)
|
||||
{
|
||||
WorldPacket data(SMSG_PLAY_MUSIC, 4);
|
||||
data << uint32(music_id);
|
||||
if (target)
|
||||
target->SendDirectMessage(&data);
|
||||
target->SendDirectMessage(WorldPackets::Misc::PlayMusic(musicId, GetGUID()).Write());
|
||||
else
|
||||
SendMessageToSet(&data, true);
|
||||
SendMessageToSet(WorldPackets::Misc::PlayMusic(musicId, GetGUID()).Write(), true);
|
||||
}
|
||||
|
||||
void WorldObject::DestroyForNearbyPlayers()
|
||||
|
||||
Reference in new issue
Block a user