Core: Get rid of dirty operator workaround for ACE_Singleton class implementation
--HG-- branch : trunk
This commit is contained in:
@@ -122,11 +122,11 @@ void MailDraft::deleteIncludedItems(SQLTransaction& trans, bool inDB /*= false*/
|
||||
|
||||
void MailDraft::SendReturnToSender(uint32 sender_acc, uint32 sender_guid, uint32 receiver_guid)
|
||||
{
|
||||
Player *receiver = sObjectMgr.GetPlayer(MAKE_NEW_GUID(receiver_guid, 0, HIGHGUID_PLAYER));
|
||||
Player *receiver = sObjectMgr->GetPlayer(MAKE_NEW_GUID(receiver_guid, 0, HIGHGUID_PLAYER));
|
||||
|
||||
uint32 rc_account = 0;
|
||||
if (!receiver)
|
||||
rc_account = sObjectMgr.GetPlayerAccountIdByGUID(MAKE_NEW_GUID(receiver_guid, 0, HIGHGUID_PLAYER));
|
||||
rc_account = sObjectMgr->GetPlayerAccountIdByGUID(MAKE_NEW_GUID(receiver_guid, 0, HIGHGUID_PLAYER));
|
||||
|
||||
SQLTransaction trans = CharacterDatabase.BeginTransaction();
|
||||
|
||||
@@ -172,7 +172,7 @@ void MailDraft::SendMailTo(SQLTransaction& trans, MailReceiver const& receiver,
|
||||
if (pReceiver)
|
||||
prepareItems(pReceiver, trans); // generate mail template items
|
||||
|
||||
uint32 mailId = sObjectMgr.GenerateMailID();
|
||||
uint32 mailId = sObjectMgr->GenerateMailID();
|
||||
|
||||
time_t deliver_time = time(NULL) + deliver_delay;
|
||||
|
||||
@@ -183,7 +183,7 @@ void MailDraft::SendMailTo(SQLTransaction& trans, MailReceiver const& receiver,
|
||||
if (sender.GetMailMessageType() == MAIL_AUCTION && m_items.empty() && !m_money)
|
||||
expire_delay = sWorld.getIntConfig(CONFIG_MAIL_DELIVERY_DELAY);
|
||||
// mail from battlemaster (rewardmarks) should last only one day
|
||||
else if (sender.GetMailMessageType() == MAIL_CREATURE && sBattlegroundMgr.GetBattleMasterBG(sender.GetSenderId()) != BATTLEGROUND_TYPE_NONE)
|
||||
else if (sender.GetMailMessageType() == MAIL_CREATURE && sBattlegroundMgr->GetBattleMasterBG(sender.GetSenderId()) != BATTLEGROUND_TYPE_NONE)
|
||||
expire_delay = DAY;
|
||||
// default case: expire time if COD 3 days, if no COD 30 days
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user