mirror of
https://github.com/mangosfour/server.git
synced 2025-12-26 07:37:02 +00:00
[9602] Simplify creating mail draft with content text, cleanup includes.
This commit is contained in:
parent
b20f9138f6
commit
a27ff3e79d
12 changed files with 58 additions and 46 deletions
|
|
@ -907,6 +907,19 @@ MailReceiver::MailReceiver( Player* receiver,uint32 receiver_lowguid ) : m_recei
|
|||
{
|
||||
ASSERT(!receiver || receiver->GetGUIDLow() == receiver_lowguid);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new MailDraft object using subject and contect texts.
|
||||
*
|
||||
* @param subject The subject of the mail.
|
||||
* @param itemText The text of the body of the mail.
|
||||
*/
|
||||
MailDraft::MailDraft( std::string subject, std::string text ) : m_mailTemplateId(0), m_mailTemplateItemsNeed(false), m_subject(subject),
|
||||
m_bodyId(!text.empty() ? sObjectMgr.CreateItemText(text) : 0), m_money(0), m_COD(0)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds an item to the MailDraft.
|
||||
*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue