adds a few logitems & bumps bullethit to high/extreme, depending on if a player was hit

This commit is contained in:
Paul
2021-12-20 15:17:40 +01:00
parent d4d85b663f
commit 7757b94333
3 changed files with 12 additions and 1 deletions

View File

@@ -5,6 +5,7 @@ using Content.Shared.Body.Components;
using Content.Shared.Damage;
using Content.Shared.Database;
using JetBrains.Annotations;
using Robust.Server.GameObjects;
using Robust.Shared.Audio;
using Robust.Shared.GameObjects;
using Robust.Shared.IoC;
@@ -57,7 +58,8 @@ namespace Content.Server.Projectiles
component.DamagedEntity = true;
if (dmg is not null && EntityManager.EntityExists(component.Shooter))
_adminLogSystem.Add(LogType.BulletHit, LogImpact.Low,
_adminLogSystem.Add(LogType.BulletHit,
HasComp<ActorComponent>(otherEntity) ? LogImpact.Extreme : LogImpact.High,
$"Projectile {ToPrettyString(component.Owner):projectile} shot by {ToPrettyString(component.Shooter):user} hit {ToPrettyString(otherEntity):target} and dealt {dmg.Total:damage} damage");
}