aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/game/AchievementMgr.cpp12
-rw-r--r--src/mangosd/mangosd.conf.dist.in6
-rw-r--r--src/shared/Log.cpp2
-rw-r--r--src/shared/Log.h3
-rw-r--r--src/shared/revision_nr.h2
5 files changed, 18 insertions, 7 deletions
diff --git a/src/game/AchievementMgr.cpp b/src/game/AchievementMgr.cpp
index 6048c8ea78d..b98b1290e4d 100644
--- a/src/game/AchievementMgr.cpp
+++ b/src/game/AchievementMgr.cpp
@@ -308,7 +308,10 @@ void AchievementMgr::LoadFromDB(QueryResult *achievementResult, QueryResult *cri
void AchievementMgr::SendAchievementEarned(AchievementEntry const* achievement)
{
- sLog.outDebug("AchievementMgr::SendAchievementEarned(%u)", achievement->ID);
+ #ifdef MANGOS_DEBUG
+ if((sLog.getLogFilter() & LOG_FILTER_ACHIEVEMENT_UPDATES)==0)
+ sLog.outDebug("AchievementMgr::SendAchievementEarned(%u)", achievement->ID);
+ #endif
if(Guild* guild = objmgr.GetGuildById(GetPlayer()->GetGuildId()))
{
@@ -392,7 +395,8 @@ static const uint32 achievIdForDangeon[][4] =
*/
void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, uint32 miscvalue1, uint32 miscvalue2, Unit *unit, uint32 time)
{
- sLog.outDetail("AchievementMgr::UpdateAchievementCriteria(%u, %u, %u, %u)", type, miscvalue1, miscvalue2, time);
+ if((sLog.getLogFilter() & LOG_FILTER_ACHIEVEMENT_UPDATES)==0)
+ sLog.outDetail("AchievementMgr::UpdateAchievementCriteria(%u, %u, %u, %u)", type, miscvalue1, miscvalue2, time);
if (!sWorld.getConfig(CONFIG_GM_ALLOW_ACHIEVEMENT_GAINS) && m_player->GetSession()->GetSecurity() > SEC_PLAYER)
return;
@@ -1023,7 +1027,9 @@ AchievementCompletionState AchievementMgr::GetAchievementCompletionState(Achieve
void AchievementMgr::SetCriteriaProgress(AchievementCriteriaEntry const* entry, uint32 changeValue, ProgressType ptype)
{
- sLog.outDetail("AchievementMgr::SetCriteriaProgress(%u, %u) for (GUID:%u)", entry->ID, changeValue);
+ if((sLog.getLogFilter() & LOG_FILTER_ACHIEVEMENT_UPDATES)==0)
+ sLog.outDetail("AchievementMgr::SetCriteriaProgress(%u, %u) for (GUID:%u)", entry->ID, changeValue);
+
CriteriaProgress *progress = NULL;
CriteriaProgressMap::iterator iter = m_criteriaProgress.find(entry->ID);
diff --git a/src/mangosd/mangosd.conf.dist.in b/src/mangosd/mangosd.conf.dist.in
index b0562c95096..b2bc2d5f779 100644
--- a/src/mangosd/mangosd.conf.dist.in
+++ b/src/mangosd/mangosd.conf.dist.in
@@ -234,8 +234,9 @@ AddonChannel = 1
# 0 = Minimum; 1 = Error; 2 = Detail; 3 = Full/Debug
# Default: 0
#
-# LogFilter_TransportMoves
+# LogFilter_AchievementUpdates
# LogFilter_CreatureMoves
+# LogFilter_TransportMoves
# LogFilter_VisibilityChanges
# Log filters
# Default: 1 - not include with any log level
@@ -304,8 +305,9 @@ LogTime = 0
LogFile = "Server.log"
LogTimestamp = 0
LogFileLevel = 0
-LogFilter_TransportMoves = 1
+LogFilter_AchievementUpdates = 1
LogFilter_CreatureMoves = 1
+LogFilter_TransportMoves = 1
LogFilter_VisibilityChanges = 1
WorldLogFile = ""
DBErrorLogFile = "db_errors.log"
diff --git a/src/shared/Log.cpp b/src/shared/Log.cpp
index c0f70f4790b..2d756f65159 100644
--- a/src/shared/Log.cpp
+++ b/src/shared/Log.cpp
@@ -245,6 +245,8 @@ void Log::Initialize()
m_logFilter |= LOG_FILTER_CREATURE_MOVES;
if(sConfig.GetBoolDefault("LogFilter_VisibilityChanges", true))
m_logFilter |= LOG_FILTER_VISIBILITY_CHANGES;
+ if(sConfig.GetBoolDefault("LogFilter_AchievementUpdates", true))
+ m_logFilter |= LOG_FILTER_ACHIEVEMENT_UPDATES;
// Char log settings
m_charLog_Dump = sConfig.GetBoolDefault("CharLogDump", false);
diff --git a/src/shared/Log.h b/src/shared/Log.h
index b4344eac262..6913cc3c12c 100644
--- a/src/shared/Log.h
+++ b/src/shared/Log.h
@@ -31,7 +31,8 @@ enum LogFilters
{
LOG_FILTER_TRANSPORT_MOVES = 1,
LOG_FILTER_CREATURE_MOVES = 2,
- LOG_FILTER_VISIBILITY_CHANGES = 4
+ LOG_FILTER_VISIBILITY_CHANGES = 4,
+ LOG_FILTER_ACHIEVEMENT_UPDATES= 8
};
enum Color
diff --git a/src/shared/revision_nr.h b/src/shared/revision_nr.h
index 278a8f916ab..377261b73fd 100644
--- a/src/shared/revision_nr.h
+++ b/src/shared/revision_nr.h
@@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
- #define REVISION_NR "7417"
+ #define REVISION_NR "7418"
#endif // __REVISION_NR_H__