DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ LogMessage()

static string Debug::LogMessage ( string level,
string plugin,
string entity,
string author,
string label,
string message )
inlinestaticprivate

DEPRECATED.

См. определение в файле Debug.c строка 482

483 {
484 if (GetGame() == null || !LogManager.IsLogsEnable())
485 return string.Empty;
486
487 bool is_server_log = ( GetGame().IsServer() && GetGame().IsMultiplayer() );
488
489
490 // Formation output to external file
491 // %date{MM-dd HH:mm:ss} | %Enviroment | %Level | %Module | %Entity | %Author | %Label | %Message
492 string date = GetDate();
493 string env = "Client";
494 string msg = string.Empty;
495
496 if ( is_server_log )
497 {
498 env = "Server";
499 }
500
501 msg = string.Format("%1 | %2 | %3 | %4 | %5 | %6 | %7", date, env, level, plugin, entity, label, message);
502
503 if ( is_server_log )
504 {
505 SaveLog(msg);
506
507#ifdef DIAG_DEVELOPER // do not send log to clients on retail
508 Param1<string> msg_p = new Param1<string>(msg);
510#endif
511 }
512 else
513 {
514 SaveLog(msg);
515 }
516
517 return msg;
518 }
const CallID CALL_ID_SEND_LOG
Определения Dispatcher.c:3
Param CallMethod(CallID call_id, Param params)
Определения Dispatcher.c:36
proto native bool IsMultiplayer()
proto native bool IsServer()
static void SaveLog(string log_message)
Определения Debug.c:520
static string GetDate()
Определения Debug.c:575
proto native CGame GetGame()
static proto string Format(string fmt, void param1=NULL, void param2=NULL, void param3=NULL, void param4=NULL, void param5=NULL, void param6=NULL, void param7=NULL, void param8=NULL, void param9=NULL)
Gets n-th character from string.

Перекрестные ссылки CALL_ID_SEND_LOG, CallMethod(), string::Empty, string::Format(), GetDate(), GetGame(), LogManager::IsLogsEnable(), CGame::IsMultiplayer(), CGame::IsServer() и SaveLog().

Используется в ActionLog(), BaseBuildingLog(), BleedingChancesLog(), InventoryHFSMLog(), InventoryMoveLog(), InventoryReservationLog(), Log(), LogArrayInt(), LogArrayString(), LogError(), LogInfo(), LogWarning(), MeleeLog(), ParticleLog(), QuickbarLog(), SymptomLog(), TFLog(), TriggerLog() и WeatherLog().