You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
52 lines
1.5 KiB
52 lines
1.5 KiB
using System;
|
|
using Sog;
|
|
|
|
namespace Battle
|
|
{
|
|
public static class BattleLogExtension
|
|
{
|
|
public static void TraceDetail(this BattleObj battle, string strFormat, params object[] argvList)
|
|
{
|
|
if (battle == null || battle.BattleId == 0)
|
|
{
|
|
TraceLog.TraceDetail(strFormat, argvList);
|
|
return;
|
|
}
|
|
|
|
TraceLog.BattleTraceDetail(battle.LogUid, battle.BattleId, battle.round, strFormat, argvList);
|
|
}
|
|
|
|
public static void Trace(this BattleObj battle, string strFormat, params object[] argvList)
|
|
{
|
|
if (battle == null || battle.BattleId == 0)
|
|
{
|
|
TraceLog.Trace(strFormat, argvList);
|
|
return;
|
|
}
|
|
|
|
TraceLog.BattleTrace(battle.LogUid, battle.BattleId, battle.round, strFormat, argvList);
|
|
}
|
|
|
|
public static void Debug(this BattleObj battle, string strFormat, params object[] argvList)
|
|
{
|
|
if (battle == null || battle.BattleId == 0)
|
|
{
|
|
TraceLog.Debug(strFormat, argvList);
|
|
return;
|
|
}
|
|
|
|
TraceLog.BattleDebug(battle.LogUid, battle.BattleId, battle.round, strFormat, argvList);
|
|
}
|
|
|
|
public static void Error(this BattleObj battle, string strFormat, params object[] argvList)
|
|
{
|
|
if (battle == null || battle.BattleId == 0)
|
|
{
|
|
TraceLog.Error(strFormat, argvList);
|
|
return;
|
|
}
|
|
|
|
TraceLog.BattleError(battle.LogUid, battle.BattleId, battle.round, strFormat, argvList);
|
|
}
|
|
}
|
|
}
|
|
|