This commit is contained in:
CortexCore
2025-06-26 23:34:50 +08:00
parent a772331918
commit 1e4643f20f
15 changed files with 318 additions and 17 deletions

View File

@@ -83,8 +83,16 @@ namespace Net.Project.B.Health
}
_knockedHealth.TryAdd(id, 100);
_knocked.Add(id);
_onKnocked?.Invoke(id, true);
// _logger.LogInformation($"Entity {id} 被击倒了");
try
{
_onKnocked?.Invoke(id, true);
}
catch (Exception e)
{
_logger.LogCritical(e, e.Message);
}
// _logger.LogInformation($"Entity {id} 被击倒了");
//return 0;
return -Math.Abs(oldHp-1);
}