mirror of
https://github.com/mangosfour/server.git
synced 2025-12-15 19:37:02 +00:00
[8156] Some mail show flags use.
This commit is contained in:
parent
02caaf3421
commit
1b8ad033c5
2 changed files with 19 additions and 2 deletions
|
|
@ -29,6 +29,15 @@
|
||||||
#include "Language.h"
|
#include "Language.h"
|
||||||
#include "DBCStores.h"
|
#include "DBCStores.h"
|
||||||
|
|
||||||
|
enum MailShowFlags
|
||||||
|
{
|
||||||
|
MAIL_SHOW_UNK0 = 0x0001,
|
||||||
|
MAIL_SHOW_DELETE = 0x0002, // forced show delete button instead return button
|
||||||
|
MAIL_SHOW_AUCTION = 0x0004, // from old comment
|
||||||
|
MAIL_SHOW_COD = 0x0008, // show subject prefix
|
||||||
|
MAIL_SHOW_UNK4 = 0x0010,
|
||||||
|
};
|
||||||
|
|
||||||
void MailItem::deleteItem( bool inDB )
|
void MailItem::deleteItem( bool inDB )
|
||||||
{
|
{
|
||||||
if(item)
|
if(item)
|
||||||
|
|
@ -601,6 +610,14 @@ void WorldSession::HandleGetMailList(WorldPacket & recv_data )
|
||||||
if(data.wpos()+next_mail_size > maxPacketSize)
|
if(data.wpos()+next_mail_size > maxPacketSize)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
uint32 show_flags = 0;
|
||||||
|
if ((*itr)->messageType != MAIL_NORMAL)
|
||||||
|
show_flags |= MAIL_SHOW_DELETE;
|
||||||
|
if ((*itr)->messageType == MAIL_AUCTION)
|
||||||
|
show_flags |= MAIL_SHOW_AUCTION;
|
||||||
|
if ((*itr)->COD)
|
||||||
|
show_flags |= MAIL_SHOW_COD;
|
||||||
|
|
||||||
data << (uint16) 0x0040; // unknown 2.3.0, different values
|
data << (uint16) 0x0040; // unknown 2.3.0, different values
|
||||||
data << (uint32) (*itr)->messageID; // Message ID
|
data << (uint32) (*itr)->messageID; // Message ID
|
||||||
data << (uint8) (*itr)->messageType; // Message Type
|
data << (uint8) (*itr)->messageType; // Message Type
|
||||||
|
|
@ -624,7 +641,7 @@ void WorldSession::HandleGetMailList(WorldPacket & recv_data )
|
||||||
data << (uint32) 0; // unknown
|
data << (uint32) 0; // unknown
|
||||||
data << (uint32) (*itr)->stationery; // stationery (Stationery.dbc)
|
data << (uint32) (*itr)->stationery; // stationery (Stationery.dbc)
|
||||||
data << (uint32) (*itr)->money; // Gold
|
data << (uint32) (*itr)->money; // Gold
|
||||||
data << (uint32) 0x04; // unknown, 0x4 - auction, 0x10 - normal
|
data << (uint32) show_flags; // unknown, 0x4 - auction, 0x10 - normal
|
||||||
// Time
|
// Time
|
||||||
data << (float) ((*itr)->expire_time-time(NULL))/DAY;
|
data << (float) ((*itr)->expire_time-time(NULL))/DAY;
|
||||||
data << (uint32) (*itr)->mailTemplateId; // mail template (MailTemplate.dbc)
|
data << (uint32) (*itr)->mailTemplateId; // mail template (MailTemplate.dbc)
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "8155"
|
#define REVISION_NR "8156"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue