update log

This commit is contained in:
NguyenVanDat
2025-12-17 17:30:27 +07:00
parent 1bc54fa74a
commit 58b3c3640a
2 changed files with 11 additions and 1 deletions
@@ -349,7 +349,10 @@ namespace BrewMonster.Network
}
public static void c2s_CmdTaskNotify( byte[] pBuf, uint sz)
{
Instance._gameSession.c2s_SendCmdTaskNotify( pBuf, sz);
if (Instance != null && Instance._gameSession != null)
{
Instance._gameSession.c2s_SendCmdTaskNotify( pBuf, sz);
}
}
public static void c2s_CmdAutoTeamSetGoal(int type, int goal_id, int op)
@@ -191,11 +191,18 @@ namespace BrewMonster.Scripts.Task
// background thread
loadedTasks = await UniTask.RunOnThreadPool(() => LoadTasksFromPack_Internal(szPackPath, onProgress, token), cancellationToken: token);
}
catch (OperationCanceledException)
{
// ❗ Đây là cancel bình thường → KHÔNG log error
Debug.Log("LoadTasksFromPack canceled");
return false;
}
catch (Exception e)
{
Debug.LogException(e);
return false;
}
Debug.Log($" Starting to load {loadedTasks.Count} task templates...");