Добавил админ логирование PacifiedOnChaplainActionSystem (#19)

Update PacifiedOnChaplainActionSystem.cs

(cherry picked from commit f6aa42eab7cce294336aec14f7dfb6f0671267cf)
This commit is contained in:
BIGZi0348
2024-10-13 14:38:04 +03:00
committed by keslik
parent 85ea507f53
commit 92444a46ec

View File

@@ -6,6 +6,8 @@ using Content.Shared.Verbs;
using Content.Server.Bible.Components;
using Content.Shared.Timing;
using Content.Shared.CombatMode.Pacification;
using Content.Server.Administration.Logs;
using Content.Shared.Database;
namespace Content.Server._White._Engi.PacifiedOnChaplainAction
{
@@ -18,6 +20,7 @@ namespace Content.Server._White._Engi.PacifiedOnChaplainAction
[Dependency] private readonly PopupSystem _popupSystem = default!;
[Dependency] private readonly SharedAudioSystem _audio = default!;
[Dependency] private readonly UseDelaySystem _delay = default!;
[Dependency] private readonly IAdminLogManager _adminLogger = default!;
public override void Initialize()
{
@@ -42,6 +45,10 @@ namespace Content.Server._White._Engi.PacifiedOnChaplainAction
EnsureComp<PacifiedComponent>(target);
}
_adminLogger.Add(LogType.Verb,
LogImpact.Medium,
$"{ToPrettyString(target):target} {popup} {ToPrettyString(user):user}");
_popupSystem.PopupEntity(Loc.GetString(popup, ("target", target)), user, user);
_audio.PlayPvs(component.ActionSound, user);