mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-13 10:31:29 +00:00
Removal of rule based settings, moving to separate DB table
This commit is contained in:
parent
72b53ee2a5
commit
99a0012bdd
@ -19,7 +19,6 @@
|
||||
|
||||
#include "eqemu_logsys.h"
|
||||
#include "string_util.h"
|
||||
#include "rulesys.h"
|
||||
#include "platform.h"
|
||||
|
||||
#include <iostream>
|
||||
@ -146,7 +145,6 @@ std::string EQEmuLogSys::FormatDebugCategoryMessageString(uint16 log_category, s
|
||||
|
||||
void EQEmuLogSys::LogDebugType(DebugLevel debug_level, uint16 log_category, std::string message, ...)
|
||||
{
|
||||
if (RuleI(Logging, DebugLogLevel) < debug_level){ return; }
|
||||
|
||||
va_list args;
|
||||
va_start(args, message);
|
||||
@ -180,8 +178,6 @@ void EQEmuLogSys::ProcessLogWrite(uint16 log_type, std::string message){
|
||||
|
||||
void EQEmuLogSys::LogDebug(DebugLevel debug_level, std::string message, ...)
|
||||
{
|
||||
if (RuleI(Logging, DebugLogLevel) < debug_level){ return; }
|
||||
|
||||
va_list args;
|
||||
va_start(args, message);
|
||||
std::string output_message = vStringFormat(message.c_str(), args);
|
||||
@ -210,15 +206,9 @@ void EQEmuLogSys::MakeDirectory(std::string directory_name){
|
||||
|
||||
void EQEmuLogSys::Log(uint16 log_type, const std::string message, ...)
|
||||
{
|
||||
|
||||
if (log_type > EQEmuLogSys::MaxLogID){
|
||||
return;
|
||||
}
|
||||
if (!RuleB(Logging, LogFileCommands) && log_type == EQEmuLogSys::LogType::Commands){ return; }
|
||||
|
||||
if (!RuleB(Logging, EnableFileLogging)){
|
||||
return;
|
||||
}
|
||||
|
||||
va_list args;
|
||||
va_start(args, message);
|
||||
@ -235,10 +225,6 @@ void EQEmuLogSys::ConsoleMessage(uint16 log_type, const std::string message)
|
||||
if (log_type > EQEmuLogSys::MaxLogID){
|
||||
return;
|
||||
}
|
||||
if (!RuleB(Logging, EnableConsoleLogging)){
|
||||
return;
|
||||
}
|
||||
if (!RuleB(Logging, ConsoleLogCommands) && log_type == EQEmuLogSys::LogType::Commands){ return; }
|
||||
|
||||
#ifdef _WINDOWS
|
||||
HANDLE console_handle;
|
||||
|
||||
@ -596,18 +596,6 @@ RULE_CATEGORY( Client )
|
||||
RULE_BOOL( Client, UseLiveFactionMessage, false) // Allows players to see faction adjustments like Live
|
||||
RULE_CATEGORY_END()
|
||||
|
||||
RULE_CATEGORY(Logging)
|
||||
RULE_BOOL(Logging, ConsoleLogCommands, false) /* Turns on or off console logs */
|
||||
RULE_BOOL(Logging, LogFileCommands, false)
|
||||
|
||||
RULE_INT(Logging, DebugLogLevel, 0) /* Sets Debug Level, -1 = OFF, 0 = Low Level, 1 = Info, 2 = Extreme */
|
||||
|
||||
RULE_BOOL(Logging, EnableConsoleLogging, true) /* Turns on or off ALL logging to console */
|
||||
RULE_BOOL(Logging, EnableFileLogging, true) /* Turns on or off ALL forms of file logging */
|
||||
|
||||
RULE_CATEGORY_END()
|
||||
|
||||
|
||||
#undef RULE_CATEGORY
|
||||
#undef RULE_INT
|
||||
#undef RULE_REAL
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user