Nothing special, took me 5 min
.
Lobby Logger:
Code:
MMatchServer_Channel.cpp, look for:
Code:
bool MMatchServer::ChannelChat(const MUID& uidPlayer, const MUID& uidChannel, char* pszChat)
Paste under:
Code:
pCmd->AddParameter(new MCommandParameterInt(nGrade));
This:
Code:
if( uidChannel == pObj->GetChannelUID() )
{
LOG(LOG_PROG, "[Lobby] | %s : %s ", pObj->GetName(), pszChat);
}
Stage Logger:
Code:
MMatchServer_Stage.cpp, look for:
Code:
bool MMatchServer::StageChat(const MUID& uidPlayer, const MUID& uidStage, char* pszChat)
Paste under:
Code:
pCmd->AddParameter(new MCommandParameterString(pszChat));
This:
Code:
if( uidStage == pObj->GetStageUID() )
{
LOG(LOG_PROG, "[Stage] | %s : %s ", pObj->GetName(), pszChat);
}
Note:
Code:
LOG_PROG would display in both log file and matchserver screen.
LOG_FILE would display only in log file of the matchserver.
Photo from matchserver screen:
Code from matchserver log file:
Code:
../Log
[07/04/12 00:04:43] [Lobby] | RaGEZONE : This is lobby.
[07/04/12 00:04:49] [Stage] | RaGEZONE : This is stage.
Adding custom file: (Didn't test);

Originally Posted by
Mocro
To add Log File.
MCommandCommunicator.h :
Search for:
add:
MCommandCommunicator.cpp
search for:
Code:
void MCommandCommunicator::LOG(unsigned int nLogLevel, const char *pFormat,...)
{
add:
Code:
if (nLogLevel == LOG_FILELOBBY){
FILE * pFile;
pFile = fopen ("Logs/lobby.txt","w");
if (pFile!=NULL)
{
va_list args;
static char temp[1024];
va_start(args, pFormat);
vsprintf(temp, pFormat, args);
fputs (temp,pFile);
fclose (pFile);
}
}else
To use function:
Code:
LOG(LOG_FILELOBBY, "[Lobby] | %s : %s ", pObj->GetName(), pszChat);
Like if you gonna use it