From 1b45aae1a19d95b4ccf3bcabf22aa8393dffdeaf Mon Sep 17 00:00:00 2001 From: Cyberium Date: Tue, 6 Feb 2024 14:29:15 +0100 Subject: [PATCH] Fix type of last dword in MSG_QUERY_NEXT_MAIL_TIME also remove gameobject as sender for now. --- src/game/Mails/MailHandler.cpp | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/src/game/Mails/MailHandler.cpp b/src/game/Mails/MailHandler.cpp index 4bd0dc1700..d576c0e297 100644 --- a/src/game/Mails/MailHandler.cpp +++ b/src/game/Mails/MailHandler.cpp @@ -798,34 +798,24 @@ void WorldSession::HandleQueryNextMailTime(WorldPacket& /**recv_data*/) if (now < m->deliver_time) continue; - HighGuid guidType = HIGHGUID_PLAYER; - - switch (m->messageType) - { - case MAIL_CREATURE: - guidType = HIGHGUID_UNIT; - break; - case MAIL_GAMEOBJECT: - guidType = HIGHGUID_GAMEOBJECT; - break; - } + HighGuid guidType = m->messageType == MAIL_CREATURE ? HIGHGUID_UNIT : HIGHGUID_PLAYER; data << ObjectGuid(guidType, m->sender); // sender guid data << static_cast(m->sender); // sender id data << static_cast(m->messageType); // message type data << uint32(m->stationery); - data << uint32(0xC6000000); // float unk, time or something + data << float(0); // delay hiding the sender (hide sender when hovering mail icon) ++count; - if (count == 2) // do not display more than 2 mails + if (count == 2) // do not display more than 2 mails break; } data.put(4, count); } else { - data << uint32(0xC7A8C000); + data << float(-86400); data << uint32(0x00000000); } SendPacket(data);