From: Chief-Engineer <119664036+Chief-Engineer@users.noreply.github.com> Date: Sun, 19 Feb 2023 05:38:38 +0000 (-0600) Subject: add clumsy deletion logs (#14172) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=546c3fb5ddc74654f077f1ed364765332e51b107;p=space-station-14.git add clumsy deletion logs (#14172) --- diff --git a/Content.Server/Weapons/Ranged/Systems/GunSystem.cs b/Content.Server/Weapons/Ranged/Systems/GunSystem.cs index 3443534a5e..cf4d6c7f8b 100644 --- a/Content.Server/Weapons/Ranged/Systems/GunSystem.cs +++ b/Content.Server/Weapons/Ranged/Systems/GunSystem.cs @@ -1,4 +1,5 @@ using System.Linq; +using Content.Server.Administration.Logs; using Content.Server.Cargo.Systems; using Content.Server.Examine; using Content.Server.Interaction; @@ -35,6 +36,7 @@ public sealed partial class GunSystem : SharedGunSystem [Dependency] private readonly PricingSystem _pricing = default!; [Dependency] private readonly StaminaSystem _stamina = default!; [Dependency] private readonly StunSystem _stun = default!; + [Dependency] private readonly IAdminLogManager _adminLogger = default!; public const float DamagePitchVariation = MeleeWeaponSystem.DamagePitchVariation; public const float GunClumsyChance = 0.5f; @@ -79,6 +81,7 @@ public sealed partial class GunSystem : SharedGunSystem Audio.PlayPvs(new SoundPathSpecifier("/Audio/Items/bikehorn.ogg"), gun.Owner); PopupSystem.PopupEntity(Loc.GetString("gun-clumsy"), user.Value); + _adminLogger.Add(LogType.EntityDelete, LogImpact.Medium, $"Clumsy fire by {ToPrettyString(user.Value)} deleted {ToPrettyString(gun.Owner)}"); Del(gun.Owner); return; }