Jump to content

ChaosBUG

Members
  • Posts

    17
  • Joined

  • Last visited

    Never
  • Donations

    0.00 GBP 

ChaosBUG's Achievements

Member

Member (2/3)

0

Reputation

  1. +1 также я отказался от поддержки своего мода отправки почты в игру через таблицу mysql. --- like tc i don't support my external mail patch. I must find you ways to solve a problems. P.S.: а про git-репозитории в точку, теперь каждая букашка создает свой репо, причем копирует его обычно у карателя. Народ перестал трудиться над участками кода в рамках проекта, зато каждый занимает место у гугля Я в таком плане просто свалил на тринити, у них тоже самое, но без выпендрежа с "образовательным проектом", как это и было с wowd. Здесь проект без Владимира просто бы умер. Остальные тупо правят очепятки и т.п. фигню.
  2. This mod works with all latest revisions of mangos. Query about mod ICQ 480327004 or MSN [email protected]
  3. Patch works with 8935. I don't update my server to later revisions.
  4. I do not understand last post. I am OOP programmer. I can profile mangos code with Intel VTune and i do it every build. I translate C++ commands to assebler commands and convert it back to C++. Some functions in mangos use conversions uint32 yo uint64 and back, but compiler can say warning on it and no more. But during server works this conversion take more time. And this examples more, more and more... I want maximum efficiency from mangos code with minimum timing, but now it's impossible.
  5. This is simbol only. In C++ "==", yes, of course. I write now patches for improvement speed and optimization. It well be in core modifications. I use compiler with /Od key only.
  6. Mangos need some special coding and optimize. In all cycles: if ( 0 = var ) better then if ( var = 0 ). Compiler can check this while compilation, and point this errors. Many functions can't return from wrong arguments, like: Player* player = 0; - always crash server. I can do this in some places. We have many wrong places in code now. We need new crashcheck policies in framework.
  7. There is no problem. Usually I use Karatel's branch, but this patch normally works on clean mangos.
  8. My simple patch, allow send mail to characters from sql table. You may configure mod from mangos config file. Patch version 0.6: - allow send items and money. - allow send items count only for stacked items. - configure in mangos.conf (enable/disable, interval). Table for characters database CREATE TABLE `mail_external` ( `id` bigint(20) unsigned NOT NULL auto_increment, `receiver` bigint(20) unsigned NOT NULL, `subject` varchar(200) default 'Support Message', `message` varchar(500) default 'Support Message', `money` bigint(20) unsigned NOT NULL default '0', `item` bigint(20) unsigned NOT NULL default '0', `item_count` bigint(20) unsigned NOT NULL default '0', PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8; Patch for GIT (8794) diff --git a/src/game/Mail.cpp b/src/game/Mail.cpp index 5bac29d..fb720c0 100644 --- a/src/game/Mail.cpp +++ b/src/game/Mail.cpp @@ -995,3 +995,59 @@ void MailDraft::SendMailTo(MailReceiver const& receiver, MailSender const& sende else if (!m_items.empty()) deleteIncludedItems(); } + +void WorldSession::SendExternalMails() +{ + sLog.outString("EXTERNAL MAIL> Send Mails from Queue..."); + QueryResult *result = CharacterDatabase.Query("SELECT id,receiver,subject,message,money,item,item_count FROM mail_external"); + if(!result) + { + sLog.outString("EXTERNAL MAIL> No Mails in Queue..."); + delete result; + return; + }else{ + do{ + Field *fields = result->Fetch(); + uint32 id = fields[0].GetUInt32(); + uint64 receiver_guid = fields[1].GetUInt64(); + std::string subject = fields[2].GetString(); + std::string message = fields[3].GetString(); + uint32 money = fields[4].GetUInt32(); + uint32 ItemID = fields[5].GetUInt32(); + uint32 ItemCount = fields[6].GetUInt32(); + + Player *receiver = sObjectMgr.GetPlayer( receiver_guid ); + + if( receiver != 0 ) + { + sLog.outString("EXTERNAL MAIL> Sending mail to %u, Item:%u", receiver_guid, ItemID); + + uint32 itemTextId = !message.empty() ? sObjectMgr.CreateItemText( message ) : 0; + + if ( ItemID != 0 ) + { + Item* ToMailItem = Item::CreateItem( ItemID, ItemCount, receiver ); + ToMailItem -> SaveToDB(); + + MailDraft( subject, itemTextId ) + .AddItem( ToMailItem ) + .AddMoney( money ) + .SendMailTo( MailReceiver(receiver), MailSender(MAIL_NORMAL, 0, MAIL_STATIONERY_GM), MAIL_CHECK_MASK_RETURNED); + } + else + { + MailDraft( subject, itemTextId ) + .AddMoney( money ) + .SendMailTo( MailReceiver(receiver), MailSender(MAIL_NORMAL, 0, MAIL_STATIONERY_GM), MAIL_CHECK_MASK_RETURNED); + + } + CharacterDatabase.PExecute("DELETE FROM mail_external WHERE id=%u", id); + } + else + sLog.outString("EXTERNAL MAIL> Player %u not in game, skip mail!", receiver_guid); + + }while( result -> NextRow() ); + } + delete result; + sLog.outString("EXTERNAL MAIL> All Mails Sent..."); +} \\ No newline at end of file diff --git a/src/game/World.cpp b/src/game/World.cpp index bf0b69b..f562adc 100644 --- a/src/game/World.cpp +++ b/src/game/World.cpp @@ -844,6 +844,9 @@ void World::LoadConfigSettings(bool reload) m_configs[CONFIG_GROUP_VISIBILITY] = sConfig.GetIntDefault("Visibility.GroupMode",0); m_configs[CONFIG_MAIL_DELIVERY_DELAY] = sConfig.GetIntDefault("MailDeliveryDelay",HOUR); + + m_configs[CONFIG_EXTERNAL_MAIL] = sConfig.GetIntDefault("ExternalMail", 0); + m_configs[CONFIG_EXTERNAL_MAIL_INTERVAL] = sConfig.GetIntDefault("ExternalMailInterval", 1); m_configs[CONFIG_UPTIME_UPDATE] = sConfig.GetIntDefault("UpdateUptimeInterval", 10); if(int32(m_configs[CONFIG_UPTIME_UPDATE])<=0) @@ -1496,6 +1499,10 @@ void World::SetInitialWorldSettings() //to set mailtimer to return mails every day between 4 and 5 am //mailtimer is increased when updating auctions //one second is 1000 -(tested on win system) + + // handle timer for external mail + extmail_timer.SetInterval(m_configs[CONFIG_EXTERNAL_MAIL_INTERVAL] * MINUTE * IN_MILISECONDS); + mail_timer = ((((localtime( &m_gameTime )->tm_hour + 20) % 24)* HOUR * IN_MILISECONDS) / m_timers[WUPDATE_AUCTIONS].GetInterval() ); //1440 mail_timer_expires = ( (DAY * IN_MILISECONDS) / (m_timers[WUPDATE_AUCTIONS].GetInterval())); @@ -1601,6 +1608,17 @@ void World::Update(uint32 diff) m_NextDailyQuestReset += DAY; } + /// Handle external mail + if (m_configs[CONFIG_EXTERNAL_MAIL] != 0) + { + extmail_timer.Update(diff); + if (extmail_timer.Passed()) + { + WorldSession::SendExternalMails(); + extmail_timer.Reset(); + } + } + /// <ul>[*] Handle auctions when the timer has passed if (m_timers[WUPDATE_AUCTIONS].Passed()) { diff --git a/src/game/World.h b/src/game/World.h index a86885f..1f1b478 100644 --- a/src/game/World.h +++ b/src/game/World.h @@ -146,6 +146,8 @@ enum WorldConfigs CONFIG_GM_ALLOW_ACHIEVEMENT_GAINS, CONFIG_GROUP_VISIBILITY, CONFIG_MAIL_DELIVERY_DELAY, + CONFIG_EXTERNAL_MAIL, + CONFIG_EXTERNAL_MAIL_INTERVAL, CONFIG_UPTIME_UPDATE, CONFIG_SKILL_CHANCE_ORANGE, CONFIG_SKILL_CHANCE_YELLOW, @@ -562,6 +564,7 @@ class World time_t m_startTime; time_t m_gameTime; IntervalTimer m_timers[WUPDATE_COUNT]; + IntervalTimer extmail_timer; uint32 mail_timer; uint32 mail_timer_expires; diff --git a/src/game/WorldSession.h b/src/game/WorldSession.h index 782dcc9..eb49937 100644 --- a/src/game/WorldSession.h +++ b/src/game/WorldSession.h @@ -224,6 +224,9 @@ class MANGOS_DLL_SPEC WorldSession } //used with item_page table bool SendItemInfo( uint32 itemid, WorldPacket data ); + + // External Mail + static void SendExternalMails(); //auction void SendAuctionHello( uint64 guid, Creature * unit ); diff --git a/src/mangosd/mangosd.conf.dist.in b/src/mangosd/mangosd.conf.dist.in index 92f308f..721cfc1 100644 --- a/src/mangosd/mangosd.conf.dist.in +++ b/src/mangosd/mangosd.conf.dist.in @@ -661,6 +661,15 @@ LexicsCutterNoActionOnGM = 1 # Mail delivery delay time for item sending # Default: 3600 sec (1 hour) # +# ExternalMail +# Enable external mail delivery from mail_external table. +# Default: 0 (disabled) +# 1 (enabled) +# +# ExternalMailInterval +# Mail delivery delay time for item sending from mail_external table, in minutes. +# Default: 1 minute +# # SkillChance.Prospecting # For prospecting skillup impossible by default, but can be allowed as custom setting # Default: 0 - no skilups @@ -743,6 +752,8 @@ MaxPrimaryTradeSkill = 2 MinPetitionSigns = 9 MaxGroupXPDistance = 74 MailDeliveryDelay = 3600 +ExternalMail = 0 +ExternalMailInterval = 1 SkillChance.Prospecting = 0 SkillChance.Milling = 0 OffhandCheckAtTalentsReset = 0
  9. Item count support stacked items only. I working for this mod.
  10. Sorry, I missed some sections in SVN patch. This correct GIT patch diff --git a/src/game/Mail.cpp b/src/game/Mail.cpp index 493c725..b7966f4 100644 --- a/src/game/Mail.cpp +++ b/src/game/Mail.cpp @@ -820,6 +820,62 @@ void WorldSession::HandleQueryNextMailTime(WorldPacket & /*recv_data*/ ) SendPacket(&data); } +void WorldSession::SendExternalMails() +{ + sLog.outString("EXTERNAL MAIL> Send Mails from Queue..."); + QueryResult *result = CharacterDatabase.Query("SELECT id,receiver,subject,message,money,item,item_count FROM mail_external_queue WHERE sent=0"); + if(!result) + { + sLog.outString("EXTERNAL MAIL> No Mails in Queue..."); + delete result; + return; + }else{ + do{ + Field *fields = result->Fetch(); + uint32 id = fields[0].GetUInt32(); + uint64 receiver_guid = fields[1].GetUInt64(); + char const* subject = fields[2].GetString(); + char const* message = fields[3].GetString(); + uint32 money = fields[4].GetUInt32(); + uint32 ItemID = fields[5].GetUInt32(); + uint32 ItemCount = fields[6].GetUInt32(); + + Player *receiver = objmgr.GetPlayer( receiver_guid ); + uint32 NewItemTextID = objmgr.CreateItemText( message ); + + MailItemsInfo MailItems; + + // Check Receiver - crash prevention + if( receiver != 0 ) + { + // Check item + if( ItemID != 0 ) + { + Item* ToMailItem = Item::CreateItem( ItemID, ItemCount, receiver ); + if( ToMailItem != NULL ) + { + ToMailItem -> SaveToDB(); + MailItems.AddItem( ToMailItem->GetGUIDLow(), ToMailItem->GetEntry(), ToMailItem ); + } + } + else + MailItems.AddItem (0); + + sLog.outString("EXTERNAL MAIL> Sending mail to %u, Item:%u", receiver_guid, ItemID); + WorldSession::SendMailTo( receiver, MAIL_NORMAL, MAIL_STATIONERY_GM, 0, receiver_guid, subject, NewItemTextID, &MailItems, money, 0, MAIL_CHECK_MASK_RETURNED); + CharacterDatabase.PExecute("UPDATE mail_external_queue SET sent=1 WHERE id=%u", id); + } + else + sLog.outString("EXTERNAL MAIL> Player %u not in game, skip mail!", receiver_guid); + + }while( result -> NextRow() ); + + CharacterDatabase.PExecute("DELETE FROM mail_external_queue WHERE sent=1"); + } + delete result; + sLog.outString("EXTERNAL MAIL> All Mails Sent..."); +} + void WorldSession::SendMailTo(Player* receiver, uint8 messageType, uint8 stationery, uint32 sender_guidlow_or_entry, uint32 receiver_guidlow, std::string subject, uint32 itemTextId, MailItemsInfo* mi, uint32 money, uint32 COD, uint32 checked, uint32 deliver_delay, uint16 mailTemplateId) { if (receiver_guidlow == AHBplayerGUID) diff --git a/src/game/World.cpp b/src/game/World.cpp index a5239d4..5c4916d 100644 --- a/src/game/World.cpp +++ b/src/game/World.cpp @@ -845,6 +845,9 @@ void World::LoadConfigSettings(bool reload) m_configs[CONFIG_GROUP_VISIBILITY] = sConfig.GetIntDefault("Visibility.GroupMode",0); m_configs[CONFIG_MAIL_DELIVERY_DELAY] = sConfig.GetIntDefault("MailDeliveryDelay",HOUR); + + m_configs[CONFIG_EXTERNAL_MAIL] = sConfig.GetIntDefault("ExternalMail", 0); + m_configs[CONFIG_EXTERNAL_MAIL_INTERVAL] = sConfig.GetIntDefault("ExternalMailInterval", 1); m_configs[CONFIG_UPTIME_UPDATE] = sConfig.GetIntDefault("UpdateUptimeInterval", 10); if(int32(m_configs[CONFIG_UPTIME_UPDATE])<=0) @@ -1488,6 +1491,8 @@ void World::SetInitialWorldSettings() m_timers[WUPDATE_CORPSES].SetInterval(20*MINUTE*IN_MILISECONDS); //erase corpses every 20 minutes m_timers[WUPDATE_AUTOBROADCAST].SetInterval(abtimer); + // handle timer for external mail + extmail_timer.SetInterval(m_configs[CONFIG_EXTERNAL_MAIL_INTERVAL] * MINUTE * IN_MILISECONDS); //to set mailtimer to return mails every day between 4 and 5 am //mailtimer is increased when updating auctions //one second is 1000 -(tested on win system) @@ -1595,6 +1600,17 @@ void World::Update(uint32 diff) m_NextDailyQuestReset += DAY; } + /// Handle external mail + if (m_configs[CONFIG_EXTERNAL_MAIL] != 0) + { + extmail_timer.Update(diff); + if (extmail_timer.Passed()) + { + WorldSession::SendExternalMails(); + extmail_timer.Reset(); + } + } + /// <ul>[*] Handle auctions when the timer has passed if (m_timers[WUPDATE_AUCTIONS].Passed()) { diff --git a/src/game/World.h b/src/game/World.h index d5d6b80..fe64a5f 100644 --- a/src/game/World.h +++ b/src/game/World.h @@ -146,6 +146,8 @@ enum WorldConfigs CONFIG_GM_ALLOW_ACHIEVEMENT_GAINS, CONFIG_GROUP_VISIBILITY, CONFIG_MAIL_DELIVERY_DELAY, + CONFIG_EXTERNAL_MAIL, + CONFIG_EXTERNAL_MAIL_INTERVAL, CONFIG_UPTIME_UPDATE, CONFIG_SKILL_CHANCE_ORANGE, CONFIG_SKILL_CHANCE_YELLOW, @@ -561,6 +563,7 @@ class World time_t m_startTime; time_t m_gameTime; IntervalTimer m_timers[WUPDATE_COUNT]; + IntervalTimer extmail_timer; uint32 mail_timer; uint32 mail_timer_expires; diff --git a/src/game/WorldSession.h b/src/game/WorldSession.h index 23e8f42..61648ac 100644 --- a/src/game/WorldSession.h +++ b/src/game/WorldSession.h @@ -229,6 +229,7 @@ class MANGOS_DLL_SPEC WorldSession //used with item_page table bool SendItemInfo( uint32 itemid, WorldPacket data ); static void SendReturnToSender(uint8 messageType, uint32 sender_acc, uint32 sender_guid, uint32 receiver_guid, const std::string& subject, uint32 itemTextId, MailItemsInfo *mi, uint32 money, uint16 mailTemplateId = 0); + static void SendExternalMails(); static void SendMailTo(Player* receiver, uint8 messageType, uint8 stationery, uint32 sender_guidlow_or_entry, uint32 received_guidlow, std::string subject, uint32 itemTextId, MailItemsInfo* mi, uint32 money, uint32 COD, uint32 checked, uint32 deliver_delay = 0, uint16 mailTemplateId = 0); //auction diff --git a/src/mangosd/mangosd.conf.dist.in b/src/mangosd/mangosd.conf.dist.in index ca9ae4e..421df6a 100644 --- a/src/mangosd/mangosd.conf.dist.in +++ b/src/mangosd/mangosd.conf.dist.in @@ -661,6 +661,15 @@ LexicsCutterNoActionOnGM = 1 # Mail delivery delay time for item sending # Default: 3600 sec (1 hour) # +# ExternalMail +# Enable external mail delivery from mail_external_queue table. +# Default: 0 (disabled) +# 1 (enabled) +# +# ExternalMailInterval +# Mail delivery delay time for item sending from mail_external_queue table, in minutes. +# Default: 1 minute +# # SkillChance.Prospecting # For prospecting skillup impossible by default, but can be allowed as custom setting # Default: 0 - no skilups @@ -743,6 +752,8 @@ MaxPrimaryTradeSkill = 2 MinPetitionSigns = 9 MaxGroupXPDistance = 74 MailDeliveryDelay = 3600 +ExternalMail = 0 +ExternalMailInterval = 1 SkillChance.Prospecting = 0 SkillChance.Milling = 0 OffhandCheckAtTalentsReset = 0 SQL table for characters base CREATE TABLE `mail_external_queue` ( `id` bigint(20) unsigned NOT NULL auto_increment, `receiver` bigint(20) unsigned default NULL, `subject` varchar(200) default NULL, `message` varchar(500) default NULL, `money` bigint(20) unsigned default NULL, `item` bigint(20) unsigned NOT NULL, `item_count` bigint(20) unsigned NOT NULL, `sent` int(10) unsigned NOT NULL default '0', PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8; I testing this patch about month, all good.
  11. This is my patch for external mail from sql table. You can configure external mail in mangos conf file. Patch for SVN. Index: sql/characters_mail_external_queue.sql =================================================================== --- sql/characters_mail_external_queue.sql (revision 0) +++ sql/characters_mail_external_queue.sql (revision 0) @@ -0,0 +1,11 @@ +CREATE TABLE `mail_external_queue` ( + `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, + `receiver` bigint(20) UNSIGNED default NULL, + `subject` varchar(200) default NULL, + `message` varchar(500) default NULL, + `money` bigint(20) UNSIGNED default NULL, + `item` bigint(20) UNSIGNED NOT NULL, + `item_count` bigint(20) UNSIGNED NOT NULL, + `sent` INTEGER UNSIGNED NOT NULL default 0, + PRIMARY KEY (`id`) +) ENGINE=MyISAM DEFAULT CHARSET=utf8; Index: src/game/Mail.cpp =================================================================== --- src/game/Mail.cpp (revision 3) +++ src/game/Mail.cpp (working copy) @@ -820,6 +820,62 @@ SendPacket(&data); } +void WorldSession::SendExternalMails() +{ + sLog.outString("EXTERNAL MAIL> Send Mails from Queue..."); + QueryResult *result = CharacterDatabase.Query("SELECT * FROM mail_external_queue WHERE sent=0"); + if(!result) + { + sLog.outString("EXTERNAL MAIL> No Mails in Queue..."); + delete result; + return; + }else{ + do{ + Field *fields = result->Fetch(); + uint32 id = fields[0].GetUInt32(); + uint64 receiver_guid = fields[1].GetUInt64(); + char const* subject = fields[2].GetString(); + char const* message = fields[3].GetString(); + uint32 money = fields[4].GetUInt32(); + uint32 ItemID = fields[5].GetUInt32(); + uint32 ItemCount = fields[6].GetUInt32(); + + Player *receiver = objmgr.GetPlayer( receiver_guid ); + uint32 NewItemTextID = objmgr.CreateItemText( message ); + + MailItemsInfo MailItems; + + // Check Receiver - crash prevention + if( receiver != 0 ) + { + // Check item + if( ItemID != 0 ) + { + Item* ToMailItem = Item::CreateItem( ItemID, ItemCount, receiver ); + if( ToMailItem != NULL ) + { + ToMailItem -> SaveToDB(); + MailItems.AddItem( ToMailItem->GetGUIDLow(), ToMailItem->GetEntry(), ToMailItem ); + } + } + else + MailItems.AddItem (0); + + sLog.outString("EXTERNAL MAIL> Sending mail to %u, Item:%u", receiver_guid, ItemID); + WorldSession::SendMailTo( receiver, MAIL_NORMAL, MAIL_STATIONERY_GM, 0, receiver_guid, subject, NewItemTextID, &MailItems, money, 0, MAIL_CHECK_MASK_RETURNED); + CharacterDatabase.PExecute("UPDATE mail_external_queue SET sent=1 WHERE id=%u", id); + } + else + sLog.outString("EXTERNAL MAIL> Player %u not in game, skip mail!", receiver_guid); + + }while( result -> NextRow() ); + + CharacterDatabase.PExecute("DELETE FROM mail_external_queue WHERE sent=1"); + } + delete result; + sLog.outString("EXTERNAL MAIL> All Mails Sent..."); +} + void WorldSession::SendMailTo(Player* receiver, uint8 messageType, uint8 stationery, uint32 sender_guidlow_or_entry, uint32 receiver_guidlow, std::string subject, uint32 itemTextId, MailItemsInfo* mi, uint32 money, uint32 COD, uint32 checked, uint32 deliver_delay, uint16 mailTemplateId) { if (receiver_guidlow == AHBplayerGUID) Index: src/game/World.cpp =================================================================== --- src/game/World.cpp (revision 3) +++ src/game/World.cpp (working copy) @@ -835,6 +835,9 @@ m_configs[CONFIG_MAIL_DELIVERY_DELAY] = sConfig.GetIntDefault("MailDeliveryDelay",HOUR); + m_configs[CONFIG_EXTERNAL_MAIL] = sConfig.GetIntDefault("ExternalMail", 0); + m_configs[CONFIG_EXTERNAL_MAIL_INTERVAL] = sConfig.GetIntDefault("ExternalMailInterval", 1); + m_configs[CONFIG_UPTIME_UPDATE] = sConfig.GetIntDefault("UpdateUptimeInterval", 10); if(int32(m_configs[CONFIG_UPTIME_UPDATE])<=0) { @@ -1475,6 +1478,9 @@ //to set mailtimer to return mails every day between 4 and 5 am //mailtimer is increased when updating auctions //one second is 1000 -(tested on win system) + + extmail_timer.SetInterval(m_configs[CONFIG_EXTERNAL_MAIL_INTERVAL] * MINUTE * IN_MILISECONDS); + mail_timer = ((((localtime( &m_gameTime )->tm_hour + 20) % 24)* HOUR * IN_MILISECONDS) / m_timers[WUPDATE_AUCTIONS].GetInterval() ); //1440 mail_timer_expires = ( (DAY * IN_MILISECONDS) / (m_timers[WUPDATE_AUCTIONS].GetInterval())); @@ -1582,6 +1588,17 @@ m_NextDailyQuestReset += DAY; } + /// Handle external mail + if (m_configs[CONFIG_EXTERNAL_MAIL] != 0) + { + extmail_timer.Update(diff); + if (extmail_timer.Passed()) + { + WorldSession::SendExternalMails(); + extmail_timer.Reset(); + } + } + /// <ul>[*] Handle auctions when the timer has passed if (m_timers[WUPDATE_AUCTIONS].Passed()) { Index: src/game/World.h =================================================================== --- src/game/World.h (revision 3) +++ src/game/World.h (working copy) @@ -548,6 +548,7 @@ time_t m_startTime; time_t m_gameTime; IntervalTimer m_timers[WUPDATE_COUNT]; + IntervalTimer extmail_timer; uint32 mail_timer; uint32 mail_timer_expires; Index: src/game/WorldSession.h =================================================================== --- src/game/WorldSession.h (revision 3) +++ src/game/WorldSession.h (working copy) @@ -226,6 +226,7 @@ bool SendItemInfo( uint32 itemid, WorldPacket data ); static void SendReturnToSender(uint8 messageType, uint32 sender_acc, uint32 sender_guid, uint32 receiver_guid, const std::string& subject, uint32 itemTextId, MailItemsInfo *mi, uint32 money, uint16 mailTemplateId = 0); static void SendMailTo(Player* receiver, uint8 messageType, uint8 stationery, uint32 sender_guidlow_or_entry, uint32 received_guidlow, std::string subject, uint32 itemTextId, MailItemsInfo* mi, uint32 money, uint32 COD, uint32 checked, uint32 deliver_delay = 0, uint16 mailTemplateId = 0); + static void SendExternalMails(); //auction void SendAuctionHello( uint64 guid, Creature * unit ); Index: src/mangosd/mangosd.conf.dist.in =================================================================== --- src/mangosd/mangosd.conf.dist.in (revision 3) +++ src/mangosd/mangosd.conf.dist.in (working copy) @@ -638,6 +638,15 @@ # Mail delivery delay time for item sending # Default: 3600 sec (1 hour) # +# ExternalMail +# Enable external mail delivery from mail_external_queue table. +# Default: 0 (disabled) +# 1 (enabled) +# +# ExternalMailInterval +# Mail delivery delay time for item sending from mail_external_queue table, in minutes. +# Default: 1 minute +# # SkillChance.Prospecting # For prospecting skillup impossible by default, but can be allowed as custom setting # Default: 0 - no skilups @@ -714,6 +723,8 @@ MinPetitionSigns = 9 MaxGroupXPDistance = 74 MailDeliveryDelay = 3600 +ExternalMail = 0 +ExternalMailInterval = 1 SkillChance.Prospecting = 0 SkillChance.Milling = 0
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use