]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
"New player" admin logging improvements (#35961)
authorSlamBamActionman <83650252+SlamBamActionman@users.noreply.github.com>
Thu, 20 Mar 2025 19:56:51 +0000 (20:56 +0100)
committerGitHub <noreply@github.com>
Thu, 20 Mar 2025 19:56:51 +0000 (20:56 +0100)
* Initial commit

* Adjust a whoooole bunch of logs

* Also spears

* Track going crit

* Review fix

* Review fixes

47 files changed:
Content.Server/Access/Systems/AccessOverriderSystem.cs
Content.Server/Access/Systems/IdCardConsoleSystem.cs
Content.Server/Access/Systems/IdCardSystem.cs
Content.Server/Administration/Commands/ChangeCvarCommand.cs
Content.Server/Administration/Logs/AdminLogManager.cs
Content.Server/Ame/EntitySystems/AmeControllerSystem.cs
Content.Server/Anomaly/Effects/InnerBodyAnomalySystem.cs
Content.Server/Botany/SeedPrototype.cs
Content.Server/Botany/Systems/BotanySystem.Seed.cs
Content.Server/Botany/Systems/PlantHolderSystem.cs
Content.Server/Clothing/Systems/CursedMaskSystem.cs
Content.Server/Communications/CommunicationsConsoleSystem.cs
Content.Server/Construction/Completions/AdminLog.cs
Content.Server/Decals/DecalSystem.cs
Content.Server/Destructible/DestructibleSystem.cs
Content.Server/Destructible/Thresholds/Behaviors/GibBehavior.cs
Content.Server/Destructible/Thresholds/Behaviors/IThresholdBehavior.cs
Content.Server/Explosion/EntitySystems/ExplosionSystem.cs
Content.Server/Explosion/EntitySystems/TriggerSystem.Voice.cs
Content.Server/Kitchen/EntitySystems/KitchenSpikeSystem.cs
Content.Server/Materials/MaterialReclaimerSystem.cs
Content.Server/Medical/BiomassReclaimer/BiomassReclaimerSystem.cs
Content.Server/Mining/MeteorSystem.cs
Content.Server/Morgue/CrematoriumSystem.cs
Content.Server/Nutrition/EntitySystems/DrinkSystem.cs
Content.Server/Placement/PlacementLoggerSystem.cs
Content.Server/Power/EntitySystems/CableSystem.cs
Content.Server/Projectiles/ProjectileSystem.cs
Content.Server/Respawn/SpecialRespawnSystem.cs
Content.Server/Shuttles/Systems/EmergencyShuttleSystem.Console.cs
Content.Server/Singularity/EntitySystems/EventHorizonSystem.cs
Content.Server/Teleportation/HandTeleporterSystem.cs
Content.Shared.Database/LogImpact.cs
Content.Shared.Database/LogType.cs
Content.Shared/Anomaly/SharedAnomalySystem.cs
Content.Shared/CCVar/CCVars.Admin.Logs.cs
Content.Shared/Cuffs/SharedCuffableSystem.cs
Content.Shared/Mobs/Systems/MobStateSystem.StateMachine.cs
Content.Shared/Roles/SharedRoleSystem.cs
Content.Shared/Strip/SharedStrippableSystem.cs
Resources/Locale/en-US/chat/managers/chat-manager.ftl
Resources/Prototypes/Hydroponics/seeds.yml
Resources/Prototypes/Recipes/Construction/Graphs/furniture/meatspike.yml
Resources/Prototypes/Recipes/Construction/Graphs/structures/grille.yml
Resources/Prototypes/Recipes/Construction/Graphs/weapons/shiv.yml
Resources/Prototypes/Recipes/Construction/Graphs/weapons/spear.yml
Resources/Prototypes/Recipes/Crafting/Graphs/improvised/bat.yml

index a0dbc96677b5486dc3fde2cd9390a6acfa19c0fd..4bb42a30a31531bd9525675f634eed109a0ebaaf 100644 (file)
@@ -241,7 +241,7 @@ public sealed class AccessOverriderSystem : SharedAccessOverriderSystem
         var addedTags = newAccessList.Except(oldTags).Select(tag => "+" + tag).ToList();
         var removedTags = oldTags.Except(newAccessList).Select(tag => "-" + tag).ToList();
 
-        _adminLogger.Add(LogType.Action, LogImpact.Medium,
+        _adminLogger.Add(LogType.Action, LogImpact.High,
             $"{ToPrettyString(player):player} has modified {ToPrettyString(accessReaderEnt.Value):entity} with the following allowed access level holders: [{string.Join(", ", addedTags.Union(removedTags))}] [{string.Join(", ", newAccessList)}]");
 
         accessReaderEnt.Value.Comp.AccessLists = ConvertAccessListToHashSet(newAccessList);
index a9e5d9a6d3ef2c43ac42306fe2366001860f8ca3..c8fbe2ba9d9e5fb4fbcab058d4b69dd5b8523d98 100644 (file)
@@ -168,7 +168,7 @@ public sealed class IdCardConsoleSystem : SharedIdCardConsoleSystem
 
         /*TODO: ECS SharedIdCardConsoleComponent and then log on card ejection, together with the save.
         This current implementation is pretty shit as it logs 27 entries (27 lines) if someone decides to give themselves AA*/
-        _adminLogger.Add(LogType.Action, LogImpact.Medium,
+        _adminLogger.Add(LogType.Action, LogImpact.High,
             $"{ToPrettyString(player):player} has modified {ToPrettyString(targetId):entity} with the following accesses: [{string.Join(", ", addedTags.Union(removedTags))}] [{string.Join(", ", newAccessList)}]");
     }
 
index a9b08aac8b3abe5e882fc4f483d54d8494e81ab7..9057fade72214f3c967e16e073d18334d74323f4 100644 (file)
@@ -88,7 +88,7 @@ public sealed class IdCardSystem : SharedIdCardSystem
             access.Tags.Add(random.ID);
             Dirty(uid, access);
 
-            _adminLogger.Add(LogType.Action, LogImpact.Medium,
+            _adminLogger.Add(LogType.Action, LogImpact.High,
                     $"{ToPrettyString(args.Microwave)} added {random.ID} access to {ToPrettyString(uid):entity}");
 
         }
index 984c9c1077ac75ab8edf5df44259bd4d7bee353d..66f93e4ebdbbe89743d73f7a52218bcbce7d2648 100644 (file)
@@ -180,7 +180,7 @@ public sealed class ChangeCvarCommand : IConsoleCommand
                 var oldValue = _configurationManager.GetCVar<object>(cvar);
                 _configurationManager.SetCVar(cvar, parsed);
                 _adminLogManager.Add(LogType.AdminCommands,
-                    LogImpact.High,
+                    LogImpact.Extreme,
                     $"{shell.Player!.Name} ({shell.Player!.UserId}) changed CVAR {cvar} from {oldValue.ToString()} to {parsed.ToString()}"
                     );
 
index e869d089dac73b9d0c1a31c6a03fe6530bfda229..b345f55ad99c5cb133717607739d29f59e431e6d 100644 (file)
@@ -6,10 +6,14 @@ using Content.Server.Database;
 using Content.Server.GameTicking;
 using Content.Shared.Administration.Logs;
 using Content.Shared.CCVar;
+using Content.Shared.Chat;
 using Content.Shared.Database;
+using Content.Shared.Players.PlayTimeTracking;
 using Prometheus;
 using Robust.Shared;
 using Robust.Shared.Configuration;
+using Robust.Shared.Network;
+using Robust.Shared.Player;
 using Robust.Shared.Reflection;
 using Robust.Shared.Timing;
 
@@ -25,6 +29,9 @@ public sealed partial class AdminLogManager : SharedAdminLogManager, IAdminLogMa
     [Dependency] private readonly IDynamicTypeFactory _typeFactory = default!;
     [Dependency] private readonly IReflectionManager _reflection = default!;
     [Dependency] private readonly IDependencyCollection _dependencies = default!;
+    [Dependency] private readonly ISharedPlayerManager _player = default!;
+    [Dependency] private readonly ISharedPlaytimeManager _playtime = default!;
+    [Dependency] private readonly ISharedChatManager _chat = default!;
 
     public const string SawmillId = "admin.logs";
 
@@ -66,6 +73,7 @@ public sealed partial class AdminLogManager : SharedAdminLogManager, IAdminLogMa
     private int _queueMax;
     private int _preRoundQueueMax;
     private int _dropThreshold;
+    private int _highImpactLogPlaytime;
 
     // Per update
     private TimeSpan _nextUpdateTime;
@@ -100,6 +108,8 @@ public sealed partial class AdminLogManager : SharedAdminLogManager, IAdminLogMa
             value => _preRoundQueueMax = value, true);
         _configuration.OnValueChanged(CCVars.AdminLogsDropThreshold,
             value => _dropThreshold = value, true);
+        _configuration.OnValueChanged(CCVars.AdminLogsHighLogPlaytime,
+            value => _highImpactLogPlaytime = value, true);
 
         if (_metricsEnabled)
         {
@@ -309,6 +319,21 @@ public sealed partial class AdminLogManager : SharedAdminLogManager, IAdminLogMa
             };
 
             log.Players.Add(player);
+            if (impact == LogImpact.Extreme) // Always chat-notify Extreme logs
+                _chat.SendAdminAlert(message);
+
+            if (impact == LogImpact.High) // Only chat-notify High logs if the player is below a threshold playtime
+            {
+                if (_highImpactLogPlaytime >= 0 && _player.TryGetSessionById(new NetUserId(id), out var session))
+                {
+                    var playtimes = _playtime.GetPlayTimes(session);
+                    if (playtimes.TryGetValue(PlayTimeTrackingShared.TrackerOverall, out var overallTime) &&
+                        overallTime <= TimeSpan.FromHours(_highImpactLogPlaytime))
+                    {
+                        _chat.SendAdminAlert(message);
+                    }
+                }
+            }
         }
 
         if (preRound)
index bc3b57bd5a3e5301dc7dec47396aa33f9476405b..7e84cbc7430c54115a7680eb3a2fba25a740e9e2 100644 (file)
@@ -240,7 +240,7 @@ public sealed class AmeControllerSystem : EntitySystem
             return;
 
         var humanReadableState = value ? "Inject" : "Not inject";
-        _adminLogger.Add(LogType.Action, LogImpact.Extreme, $"{EntityManager.ToPrettyString(user.Value):player} has set the AME to {humanReadableState}");
+        _adminLogger.Add(LogType.Action, LogImpact.Medium, $"{EntityManager.ToPrettyString(user.Value):player} has set the AME to {humanReadableState}");
     }
 
     public void ToggleInjecting(EntityUid uid, EntityUid? user = null, AmeControllerComponent? controller = null)
@@ -267,27 +267,15 @@ public sealed class AmeControllerSystem : EntitySystem
             return;
 
         var humanReadableState = controller.Injecting ? "Inject" : "Not inject";
-        _adminLogger.Add(LogType.Action, LogImpact.Extreme, $"{EntityManager.ToPrettyString(user.Value):player} has set the AME to inject {controller.InjectionAmount} while set to {humanReadableState}");
 
-        /* This needs to be information which an admin is very likely to want to be informed about in order to be an admin alert or have a sound notification.
-        At the time of editing, players regularly "overclock" the AME and those cases require no admin attention.
 
-        // Admin alert
         var safeLimit = int.MaxValue;
         if (TryGetAMENodeGroup(uid, out var group))
             safeLimit = group.CoreCount * 4;
 
-        if (oldValue <= safeLimit && value > safeLimit)
-        {
-            if (_gameTiming.CurTime > controller.EffectCooldown)
-            {
-                _chatManager.SendAdminAlert(user.Value, $"increased AME over safe limit to {controller.InjectionAmount}");
-                _audioSystem.PlayGlobal("/Audio/Misc/adminlarm.ogg",
-                    Filter.Empty().AddPlayers(_adminManager.ActiveAdmins), false, AudioParams.Default.WithVolume(-8f));
-                controller.EffectCooldown = _gameTiming.CurTime + controller.CooldownDuration;
-            }
-        }
-        */
+        var logImpact = (oldValue <= safeLimit && value > safeLimit) ? LogImpact.Extreme : LogImpact.Medium;
+
+        _adminLogger.Add(LogType.Action, logImpact, $"{EntityManager.ToPrettyString(user.Value):player} has set the AME to inject {controller.InjectionAmount} while set to {humanReadableState}");
     }
 
     public void AdjustInjectionAmount(EntityUid uid, int delta, EntityUid? user = null, AmeControllerComponent? controller = null)
index 5380a1aa0a1b2a27593154432b75b28c5ee25c67..b647e026e30191f13e8d1b9181cfc13bae75ddd7 100644 (file)
@@ -116,7 +116,7 @@ public sealed class InnerBodyAnomalySystem : SharedInnerBodyAnomalySystem
 
             _popup.PopupEntity(message, ent, ent, PopupType.MediumCaution);
 
-            _adminLog.Add(LogType.Anomaly,LogImpact.Extreme,$"{ToPrettyString(ent)} became anomaly host.");
+            _adminLog.Add(LogType.Anomaly,LogImpact.Medium,$"{ToPrettyString(ent)} became anomaly host.");
         }
         Dirty(ent);
     }
index 7c5718b56982e8f4106d437bfb023687b4c654dc..22021f1fabca8f7c397dfc3252190c0e2f53adf7 100644 (file)
@@ -1,6 +1,7 @@
 using Content.Server.Botany.Components;
 using Content.Server.Botany.Systems;
 using Content.Shared.Atmos;
+using Content.Shared.Database;
 using Content.Shared.EntityEffects;
 using Content.Shared.Random;
 using Robust.Shared.Audio;
@@ -243,6 +244,18 @@ public partial class SeedData
     [DataField(customTypeSerializer: typeof(PrototypeIdListSerializer<SeedPrototype>))]
     public List<string> MutationPrototypes = new();
 
+    /// <summary>
+    ///  Log impact for when the seed is planted.
+    /// </summary>
+    [DataField]
+    public LogImpact? PlantLogImpact = null;
+
+    /// <summary>
+    ///  Log impact for when the seed is harvested.
+    /// </summary>
+    [DataField]
+    public LogImpact? HarvestLogImpact = null;
+
     public SeedData Clone()
     {
         DebugTools.Assert(!Immutable, "There should be no need to clone an immutable seed.");
index 81645be34f40f99e69004236fe9d26b7b6337844..e10414ebe5a82cc6bf62f9d83f71115392ad7d8d 100644 (file)
@@ -14,6 +14,8 @@ using Robust.Shared.Prototypes;
 using Robust.Shared.Random;
 using System.Diagnostics.CodeAnalysis;
 using System.Linq;
+using Content.Shared.Administration.Logs;
+using Content.Shared.Database;
 
 namespace Content.Server.Botany.Systems;
 
@@ -27,6 +29,7 @@ public sealed partial class BotanySystem : EntitySystem
     [Dependency] private readonly SharedSolutionContainerSystem _solutionContainerSystem = default!;
     [Dependency] private readonly MetaDataSystem _metaData = default!;
     [Dependency] private readonly RandomHelperSystem _randomHelper = default!;
+    [Dependency] private readonly ISharedAdminLogManager _adminLogger = default!;
 
     public override void Initialize()
     {
@@ -116,7 +119,12 @@ public sealed partial class BotanySystem : EntitySystem
     {
         if (position.IsValid(EntityManager) &&
             proto.ProductPrototypes.Count > 0)
+        {
+            if (proto.HarvestLogImpact != null)
+                _adminLogger.Add(LogType.Botany, proto.HarvestLogImpact.Value, $"Auto-harvested {Loc.GetString(proto.Name):seed} at Pos:{position}.");
+
             return GenerateProduct(proto, position, yieldMod);
+        }
 
         return Enumerable.Empty<EntityUid>();
     }
@@ -131,6 +139,10 @@ public sealed partial class BotanySystem : EntitySystem
 
         var name = Loc.GetString(proto.DisplayName);
         _popupSystem.PopupCursor(Loc.GetString("botany-harvest-success-message", ("name", name)), user, PopupType.Medium);
+
+        if (proto.HarvestLogImpact != null)
+            _adminLogger.Add(LogType.Botany, proto.HarvestLogImpact.Value, $"{ToPrettyString(user):player} harvested {Loc.GetString(proto.Name):seed} at Pos:{Transform(user).Coordinates}.");
+
         return GenerateProduct(proto, Transform(user).Coordinates, yieldMod);
     }
 
index 7eda4949a95383019be576b45b581d3f0d37f274..15cb82ef00c217e01c8ad09b0e23b9d3a11d71ba 100644 (file)
@@ -23,7 +23,9 @@ using Robust.Shared.Prototypes;
 using Robust.Shared.Random;
 using Robust.Shared.Timing;
 using Content.Server.Labels.Components;
+using Content.Shared.Administration.Logs;
 using Content.Shared.Containers.ItemSlots;
+using Content.Shared.Database;
 
 namespace Content.Server.Botany.Systems;
 
@@ -42,6 +44,7 @@ public sealed class PlantHolderSystem : EntitySystem
     [Dependency] private readonly RandomHelperSystem _randomHelper = default!;
     [Dependency] private readonly IRobustRandom _random = default!;
     [Dependency] private readonly ItemSlotsSystem _itemSlots = default!;
+    [Dependency] private readonly ISharedAdminLogManager _adminLogger = default!;
 
 
     public const float HydroponicsSpeedMultiplier = 1f;
@@ -188,6 +191,9 @@ public sealed class PlantHolderSystem : EntitySystem
                 CheckLevelSanity(uid, component);
                 UpdateSprite(uid, component);
 
+                if (seed.PlantLogImpact != null)
+                    _adminLogger.Add(LogType.Botany, seed.PlantLogImpact.Value, $"{ToPrettyString(args.User):player} planted  {Loc.GetString(seed.Name):seed} at Pos:{Transform(uid).Coordinates}.");
+
                 return;
             }
 
index 86d4e801a8b000369f5f4e13e009e69c155cab24..ef23df5f1792d8d9d80327220b4af96fe74f82d4 100644 (file)
@@ -82,7 +82,7 @@ public sealed class CursedMaskSystem : SharedCursedMaskSystem
             {
                 _mind.TransferTo(ent.Comp.StolenMind.Value, args.Wearer);
                 _adminLog.Add(LogType.Action,
-                    LogImpact.Extreme,
+                    LogImpact.Medium,
                     $"{ToPrettyString(args.Wearer):player} was restored to their body after the removal of {ToPrettyString(ent):entity}.");
                 ent.Comp.StolenMind = null;
             }
index abcd93f3280623eea4ab311b2a0697fb72282c61..b4303ee50ad3d279a148e7e30eac5d07f931bef2 100644 (file)
@@ -312,7 +312,7 @@ namespace Content.Server.Communications
             }
 
             _roundEndSystem.RequestRoundEnd(uid);
-            _adminLogger.Add(LogType.Action, LogImpact.Extreme, $"{ToPrettyString(mob):player} has called the shuttle.");
+            _adminLogger.Add(LogType.Action, LogImpact.High, $"{ToPrettyString(mob):player} has called the shuttle.");
         }
 
         private void OnRecallShuttleMessage(EntityUid uid, CommunicationsConsoleComponent comp, CommunicationsConsoleRecallEmergencyShuttleMessage message)
@@ -327,7 +327,7 @@ namespace Content.Server.Communications
             }
 
             _roundEndSystem.CancelRoundEndCountdown(uid);
-            _adminLogger.Add(LogType.Action, LogImpact.Extreme, $"{ToPrettyString(message.Actor):player} has recalled the shuttle.");
+            _adminLogger.Add(LogType.Action, LogImpact.High, $"{ToPrettyString(message.Actor):player} has recalled the shuttle.");
         }
     }
 
index 82758634d9cee5331ddc5b76aa110644629a62f9..bc5b45e4a80cef8c992361ebdc821cbb69f740e1 100644 (file)
@@ -25,7 +25,7 @@ public sealed partial class AdminLog : IGraphAction
         var logManager = IoCManager.Resolve<IAdminLogManager>();
 
         if (userUid.HasValue)
-            logManager.Add(LogType, Impact, $"{Message} - Entity: {entityManager.ToPrettyString(uid):entity}, User: {entityManager.ToPrettyString(userUid.Value):user}");
+            logManager.Add(LogType, Impact, $"{Message} - Entity: {entityManager.ToPrettyString(uid):entity}, User: {entityManager.ToPrettyString(userUid.Value):player}");
         else
             logManager.Add(LogType, Impact, $"{Message} - Entity: {entityManager.ToPrettyString(uid):entity}");
     }
index 718475754f25b7f07a5b29b189fdb96d5f8fc51d..02d3ebd0a15a31528443a31dd71a275b19e473fb 100644 (file)
@@ -225,12 +225,12 @@ namespace Content.Server.Decals
 
             if (eventArgs.SenderSession.AttachedEntity != null)
             {
-                _adminLogger.Add(LogType.CrayonDraw, LogImpact.High,
+                _adminLogger.Add(LogType.CrayonDraw, LogImpact.Low,
                     $"{ToPrettyString(eventArgs.SenderSession.AttachedEntity.Value):actor} drew a {ev.Decal.Color} {ev.Decal.Id} at {ev.Coordinates}");
             }
             else
             {
-                _adminLogger.Add(LogType.CrayonDraw, LogImpact.High,
+                _adminLogger.Add(LogType.CrayonDraw, LogImpact.Low,
                     $"{eventArgs.SenderSession.Name} drew a {ev.Decal.Color} {ev.Decal.Id} at {ev.Coordinates}");
             }
         }
@@ -259,12 +259,12 @@ namespace Content.Server.Decals
             {
                 if (eventArgs.SenderSession.AttachedEntity != null)
                 {
-                    _adminLogger.Add(LogType.CrayonDraw, LogImpact.High,
+                    _adminLogger.Add(LogType.CrayonDraw, LogImpact.Low,
                         $"{ToPrettyString(eventArgs.SenderSession.AttachedEntity.Value):actor} removed a {decal.Color} {decal.Id} at {ev.Coordinates}");
                 }
                 else
                 {
-                    _adminLogger.Add(LogType.CrayonDraw, LogImpact.High,
+                    _adminLogger.Add(LogType.CrayonDraw, LogImpact.Low,
                         $"{eventArgs.SenderSession.Name} removed a {decal.Color} {decal.Id} at {ev.Coordinates}");
                 }
 
index f156d517a3a594e6320e3b58e94b9c0af65b6452..48b38e9d0194d3463894f3bff3471152baae1a5a 100644 (file)
@@ -21,6 +21,8 @@ using Robust.Shared.Containers;
 using Robust.Shared.Prototypes;
 using Robust.Shared.Random;
 using System.Linq;
+using Content.Shared.Humanoid;
+using Robust.Shared.Player;
 
 namespace Content.Server.Destructible
 {
@@ -61,9 +63,12 @@ namespace Content.Server.Destructible
                 {
                     RaiseLocalEvent(uid, new DamageThresholdReached(component, threshold), true);
 
+                    var logImpact = LogImpact.Low;
                     // Convert behaviors into string for logs
                     var triggeredBehaviors = string.Join(", ", threshold.Behaviors.Select(b =>
                     {
+                        if (logImpact <= b.Impact)
+                            logImpact = b.Impact;
                         if (b is DoActsBehavior doActsBehavior)
                         {
                             return $"{b.GetType().Name}:{doActsBehavior.Acts.ToString()}";
@@ -71,14 +76,20 @@ namespace Content.Server.Destructible
                         return b.GetType().Name;
                     }));
 
+                    // If it doesn't have a humanoid component, it's probably not particularly notable?
+                    if (logImpact > LogImpact.Medium && !HasComp<HumanoidAppearanceComponent>(uid))
+                        logImpact = LogImpact.Medium;
+
                     if (args.Origin != null)
                     {
-                        _adminLogger.Add(LogType.Damaged, LogImpact.Medium,
+                        _adminLogger.Add(LogType.Damaged,
+                            logImpact,
                             $"{ToPrettyString(args.Origin.Value):actor} caused {ToPrettyString(uid):subject} to trigger [{triggeredBehaviors}]");
                     }
                     else
                     {
-                        _adminLogger.Add(LogType.Damaged, LogImpact.Medium,
+                        _adminLogger.Add(LogType.Damaged,
+                            logImpact,
                             $"Unknown damage source caused {ToPrettyString(uid):subject} to trigger [{triggeredBehaviors}]");
                     }
 
index c83fed1906962b53b55c2c50d45b924657698eda..9aa798a3d093385d11717d367e2b2f6263bf7154 100644 (file)
@@ -1,4 +1,5 @@
 using Content.Shared.Body.Components;
+using Content.Shared.Database;
 using JetBrains.Annotations;
 
 namespace Content.Server.Destructible.Thresholds.Behaviors
@@ -9,6 +10,8 @@ namespace Content.Server.Destructible.Thresholds.Behaviors
     {
         [DataField("recursive")] private bool _recursive = true;
 
+        public LogImpact Impact => LogImpact.Extreme;
+
         public void Execute(EntityUid owner, DestructibleSystem system, EntityUid? cause = null)
         {
             if (system.EntityManager.TryGetComponent(owner, out BodyComponent? body))
index b5e78fd80c5ff59d100b40110f0dd50b28d81dfc..0cf0cc032cd96254e56294d9a95d74671b2c73ed 100644 (file)
@@ -1,7 +1,11 @@
-namespace Content.Server.Destructible.Thresholds.Behaviors
+using Content.Shared.Database;
+
+namespace Content.Server.Destructible.Thresholds.Behaviors
 {
     public interface IThresholdBehavior
     {
+        public LogImpact Impact => LogImpact.Low;
+
         /// <summary>
         ///     Executes this behavior.
         /// </summary>
index 57759fedfe9f0f52751b664781e89e8a28bc1686..6bf237f46fadbcbc9cce75b144b6cd5ff6aadf78 100644 (file)
@@ -256,11 +256,12 @@ public sealed partial class ExplosionSystem : SharedExplosionSystem
         }
         else
         {
-            _adminLogger.Add(LogType.Explosion, LogImpact.High,
-                $"{ToPrettyString(user.Value):user} caused {ToPrettyString(uid):entity} to explode ({typeId}) at Pos:{(posFound ? $"{gridPos:coordinates}" : "[Grid or Map not found]")} with intensity {totalIntensity} slope {slope}");
             var alertMinExplosionIntensity = _cfg.GetCVar(CCVars.AdminAlertExplosionMinIntensity);
-            if (alertMinExplosionIntensity > -1 && totalIntensity >= alertMinExplosionIntensity)
-                _chat.SendAdminAlert(user.Value, $"caused {ToPrettyString(uid)} to explode ({typeId}:{totalIntensity}) at Pos:{(posFound ? $"{gridPos:coordinates}" : "[Grid or Map not found]")}");
+            var logImpact = (alertMinExplosionIntensity > -1 && totalIntensity >= alertMinExplosionIntensity)
+                ? LogImpact.Extreme
+                : LogImpact.High;
+            _adminLogger.Add(LogType.Explosion, logImpact,
+                $"{ToPrettyString(user.Value):user} caused {ToPrettyString(uid):entity} to explode ({typeId}) at Pos:{(posFound ? $"{gridPos:coordinates}" : "[Grid or Map not found]")} with intensity {totalIntensity} slope {slope}");
         }
     }
 
index 8dd170e6676201292adcbb8f417329ca9a0a4a9a..9d11a9dad770ca23c4cae9c76eca575efa532e0b 100644 (file)
@@ -50,7 +50,7 @@ namespace Content.Server.Explosion.EntitySystems
 
             if (!string.IsNullOrWhiteSpace(component.KeyPhrase) && message.Contains(component.KeyPhrase, StringComparison.InvariantCultureIgnoreCase))
             {
-                _adminLogger.Add(LogType.Trigger, LogImpact.High,
+                _adminLogger.Add(LogType.Trigger, LogImpact.Medium,
                         $"A voice-trigger on {ToPrettyString(ent):entity} was triggered by {ToPrettyString(args.Source):speaker} speaking the key-phrase {component.KeyPhrase}.");
                 Trigger(ent, args.Source);
 
index 9b70426faa7f0f1c30ae45562eaea33e49b7070f..6f28331ade4a6b13589667f17b0c8b40fa2a9e63 100644 (file)
@@ -7,6 +7,7 @@ using Content.Shared.Damage;
 using Content.Shared.Database;
 using Content.Shared.DoAfter;
 using Content.Shared.DragDrop;
+using Content.Shared.Humanoid;
 using Content.Shared.IdentityManagement;
 using Content.Shared.Interaction;
 using Content.Shared.Interaction.Events;
@@ -143,7 +144,11 @@ namespace Content.Server.Kitchen.EntitySystems
             if (!Resolve(uid, ref component) || !Resolve(victimUid, ref butcherable))
                 return;
 
-            _logger.Add(LogType.Gib, LogImpact.Extreme, $"{ToPrettyString(userUid):user} kitchen spiked {ToPrettyString(victimUid):target}");
+            var logImpact = LogImpact.Medium;
+            if (HasComp<HumanoidAppearanceComponent>(victimUid))
+                logImpact = LogImpact.Extreme;
+
+            _logger.Add(LogType.Gib, logImpact, $"{ToPrettyString(userUid):user} kitchen spiked {ToPrettyString(victimUid):target}");
 
             // TODO VERY SUS
             component.PrototypesToSpawn = EntitySpawnCollection.GetSpawns(butcherable.SpawnedEntities, _random);
index d179284595dac1a20b17124db7d6a6ea1dc20ccb..60b1a99e31d6a9aa042dac08ba799bd784da89b4 100644 (file)
@@ -24,6 +24,7 @@ using Robust.Shared.Player;
 using Robust.Shared.Prototypes;
 using Robust.Shared.Utility;
 using System.Linq;
+using Content.Shared.Humanoid;
 
 namespace Content.Server.Materials;
 
@@ -186,7 +187,8 @@ public sealed class MaterialReclaimerSystem : SharedMaterialReclaimerSystem
 
         if (CanGib(uid, item, component))
         {
-            _adminLogger.Add(LogType.Gib, LogImpact.Extreme, $"{ToPrettyString(item):victim} was gibbed by {ToPrettyString(uid):entity} ");
+            var logImpact = HasComp<HumanoidAppearanceComponent>(item) ? LogImpact.Extreme : LogImpact.Medium;
+            _adminLogger.Add(LogType.Gib, logImpact, $"{ToPrettyString(item):victim} was gibbed by {ToPrettyString(uid):entity} ");
             SpawnChemicalsFromComposition(uid, item, completion, false, component, xform);
             _body.GibBody(item, true);
             _appearance.SetData(uid, RecyclerVisuals.Bloody, true);
index 868e6d99f251a0a80f0dca254aa46bb6978ebc5d..f6b751c398abd6c4e53b90a8026461e16f8de508 100644 (file)
@@ -182,7 +182,7 @@ namespace Content.Server.Medical.BiomassReclaimer
                 _throwing.TryThrow(args.Climber, direction, 0.5f);
                 return;
             }
-            _adminLogger.Add(LogType.Action, LogImpact.Extreme, $"{ToPrettyString(args.Instigator):player} used a biomass reclaimer to gib {ToPrettyString(args.Climber):target} in {ToPrettyString(reclaimer):reclaimer}");
+            _adminLogger.Add(LogType.Action, LogImpact.High, $"{ToPrettyString(args.Instigator):player} used a biomass reclaimer to gib {ToPrettyString(args.Climber):target} in {ToPrettyString(reclaimer):reclaimer}");
 
             StartProcessing(args.Climber, reclaimer);
         }
@@ -195,7 +195,7 @@ namespace Content.Server.Medical.BiomassReclaimer
             if (args.Args.Used == null || args.Args.Target == null || !HasComp<BiomassReclaimerComponent>(args.Args.Target.Value))
                 return;
 
-            _adminLogger.Add(LogType.Action, LogImpact.Extreme, $"{ToPrettyString(args.Args.User):player} used a biomass reclaimer to gib {ToPrettyString(args.Args.Target.Value):target} in {ToPrettyString(reclaimer):reclaimer}");
+            _adminLogger.Add(LogType.Action, LogImpact.High, $"{ToPrettyString(args.Args.User):player} used a biomass reclaimer to gib {ToPrettyString(args.Args.Target.Value):target} in {ToPrettyString(reclaimer):reclaimer}");
             StartProcessing(args.Args.Used.Value, reclaimer);
 
             args.Handled = true;
index fc00147f70f027080cdcbe45a2de64475faa6bff..3b0c6920b3b68a510af8e90b908bddfd6a1f5a58 100644 (file)
@@ -35,7 +35,7 @@ public sealed class MeteorSystem : EntitySystem
         {
             threshold = mobThreshold.Value;
             if (HasComp<ActorComponent>(args.OtherEntity))
-                _adminLog.Add(LogType.Action, LogImpact.Extreme, $"{ToPrettyString(args.OtherEntity):player} was struck by meteor {ToPrettyString(uid):ent} and killed instantly.");
+                _adminLog.Add(LogType.Action, LogImpact.High, $"{ToPrettyString(args.OtherEntity):player} was struck by meteor {ToPrettyString(uid):ent} and killed instantly.");
         }
         else if (_destructible.TryGetDestroyedAt(args.OtherEntity, out var destroyThreshold))
         {
index 656457dc985650c53c050a34a3bf3ee41da3c27e..52f5ca312d1100dc4f9829ae0176634b721e55a1 100644 (file)
@@ -87,7 +87,7 @@ public sealed class CrematoriumSystem : EntitySystem
             Text = Loc.GetString("cremate-verb-get-data-text"),
             // TODO VERB ICON add flame/burn symbol?
             Act = () => TryCremate(uid, component, storage),
-            Impact = LogImpact.Medium // could be a body? or evidence? I dunno.
+            Impact = LogImpact.High // could be a body? or evidence? I dunno.
         };
         args.Verbs.Add(verb);
     }
index 44e90537b5dc47d9bba24ab9091a0347ea3b6275..f11a2c9041a3e30395fa9b2f20cf8f2a6777d17c 100644 (file)
@@ -195,7 +195,7 @@ public sealed class DrinkSystem : SharedDrinkSystem
             _popup.PopupEntity(Loc.GetString("drink-component-force-feed", ("user", userName)), user, target);
 
             // logging
-            _adminLogger.Add(LogType.ForceFeed, LogImpact.Medium, $"{ToPrettyString(user):user} is forcing {ToPrettyString(target):target} to drink {ToPrettyString(item):drink} {SharedSolutionContainerSystem.ToPrettyString(drinkSolution)}");
+            _adminLogger.Add(LogType.ForceFeed, LogImpact.High, $"{ToPrettyString(user):user} is forcing {ToPrettyString(target):target} to drink {ToPrettyString(item):drink} {SharedSolutionContainerSystem.ToPrettyString(drinkSolution)}");
         }
         else
         {
index d590754423dd108f6876bd7688138f099d99fc34..55fc3b7f6fdc13f0870630a62c3ac95b157e1f6b 100644 (file)
@@ -32,13 +32,13 @@ public sealed class PlacementLoggerSystem : EntitySystem
         };
 
         if (actorEntity != null)
-            _adminLogger.Add(logType, LogImpact.High,
+            _adminLogger.Add(logType, LogImpact.Medium,
                 $"{ToPrettyString(actorEntity.Value):actor} used placement system to {ev.PlacementEventAction.ToString().ToLower()} {ToPrettyString(ev.EditedEntity):subject} at {ev.Coordinates}");
         else if (actor != null)
-            _adminLogger.Add(logType, LogImpact.High,
+            _adminLogger.Add(logType, LogImpact.Medium,
                 $"{actor:actor} used placement system to {ev.PlacementEventAction.ToString().ToLower()} {ToPrettyString(ev.EditedEntity):subject} at {ev.Coordinates}");
         else
-            _adminLogger.Add(logType, LogImpact.High,
+            _adminLogger.Add(logType, LogImpact.Medium,
                 $"Placement system {ev.PlacementEventAction.ToString().ToLower()}ed {ToPrettyString(ev.EditedEntity):subject} at {ev.Coordinates}");
     }
 
@@ -48,13 +48,13 @@ public sealed class PlacementLoggerSystem : EntitySystem
         var actorEntity = actor?.AttachedEntity;
 
         if (actorEntity != null)
-            _adminLogger.Add(LogType.Tile, LogImpact.High,
+            _adminLogger.Add(LogType.Tile, LogImpact.Medium,
                 $"{ToPrettyString(actorEntity.Value):actor} used placement system to set tile {_tileDefinitionManager[ev.TileType].Name} at {ev.Coordinates}");
         else if (actor != null)
-            _adminLogger.Add(LogType.Tile, LogImpact.High,
+            _adminLogger.Add(LogType.Tile, LogImpact.Medium,
                 $"{actor} used placement system to set tile {_tileDefinitionManager[ev.TileType].Name} at {ev.Coordinates}");
         else
-            _adminLogger.Add(LogType.Tile, LogImpact.High,
+            _adminLogger.Add(LogType.Tile, LogImpact.Medium,
                 $"Placement system set tile {_tileDefinitionManager[ev.TileType].Name} at {ev.Coordinates}");
     }
 }
index db44323007a48ac03fc7d43faa57f97aef71b587..8fc7edacf3531d5c87ed7924540a2044684d3588 100644 (file)
@@ -53,7 +53,7 @@ public sealed partial class CableSystem : EntitySystem
         if (_electrocutionSystem.TryDoElectrifiedAct(uid, args.User))
             return;
 
-        _adminLogger.Add(LogType.CableCut, LogImpact.Medium, $"The {ToPrettyString(uid)} at {xform.Coordinates} was cut by {ToPrettyString(args.User)}.");
+        _adminLogger.Add(LogType.CableCut, LogImpact.High, $"The {ToPrettyString(uid)} at {xform.Coordinates} was cut by {ToPrettyString(args.User)}.");
 
         Spawn(cable.CableDroppedOnCutPrototype, xform.Coordinates);
         QueueDel(uid);
index f1df25d58c77356517a8ade6ea2e392f9783bb43..64bb678321b3d46282e0178583bc46804dd20bae 100644 (file)
@@ -65,7 +65,7 @@ public sealed class ProjectileSystem : SharedProjectileSystem
             }
 
             _adminLogger.Add(LogType.BulletHit,
-                HasComp<ActorComponent>(target) ? LogImpact.Extreme : LogImpact.High,
+                LogImpact.Medium,
                 $"Projectile {ToPrettyString(uid):projectile} shot by {ToPrettyString(component.Shooter!.Value):user} hit {otherName:target} and dealt {modifiedDamage.GetTotal():damage} damage");
         }
 
index a403818e7429bcfd103486775a86a86c6de76940..e7a2385e74d7ef753e1fb382e456fe1f4a4422a8 100644 (file)
@@ -136,7 +136,7 @@ public sealed class SpecialRespawnSystem : SharedSpecialRespawnSystem
     private void Respawn(EntityUid oldEntity, string prototype, EntityCoordinates coords)
     {
         var entity = Spawn(prototype, coords);
-        _adminLog.Add(LogType.Respawn, LogImpact.High, $"{ToPrettyString(oldEntity)} was deleted and was respawned at {coords.ToMap(EntityManager, _transform)} as {ToPrettyString(entity)}");
+        _adminLog.Add(LogType.Respawn, LogImpact.Extreme, $"{ToPrettyString(oldEntity)} was deleted and was respawned at {coords.ToMap(EntityManager, _transform)} as {ToPrettyString(entity)}");
         _chat.SendAdminAlert($"{MetaData(oldEntity).EntityName} was deleted and was respawned as {ToPrettyString(entity)}");
     }
 
index ede0b687fcc5567dc02dd1d605906ed211873543..09aad1d931add01a40c46ac78edd312652c08376 100644 (file)
@@ -372,7 +372,7 @@ public sealed partial class EmergencyShuttleSystem
     {
         if (EarlyLaunchAuthorized || !EmergencyShuttleArrived || _consoleAccumulator <= _authorizeTime) return false;
 
-        _logger.Add(LogType.EmergencyShuttle, LogImpact.Extreme, $"Emergency shuttle launch authorized");
+        _logger.Add(LogType.EmergencyShuttle, LogImpact.High, $"Emergency shuttle launch authorized");
         _consoleAccumulator = _authorizeTime;
         EarlyLaunchAuthorized = true;
         RaiseLocalEvent(new EmergencyShuttleAuthorizedEvent());
index 2a2952916ecdbd37be91c0940777532ccf3f90d2..729328b8bd7958673de2a4ba2cad3214aece2039 100644 (file)
@@ -130,7 +130,7 @@ public sealed class EventHorizonSystem : SharedEventHorizonSystem
             || _tagSystem.HasTag(morsel, "HighRiskItem")
             || HasComp<ContainmentFieldGeneratorComponent>(morsel))
         {
-            _adminLogger.Add(LogType.EntityDelete, LogImpact.Extreme, $"{ToPrettyString(morsel)} entered the event horizon of {ToPrettyString(hungry)} and was deleted");
+            _adminLogger.Add(LogType.EntityDelete, LogImpact.High, $"{ToPrettyString(morsel):player} entered the event horizon of {ToPrettyString(hungry)} and was deleted");
         }
 
         EntityManager.QueueDeleteEntity(morsel);
index 78e881d76a05f4dc92c0ef575aba3657607b53ef..5c9baf18546e5104bd9be9a467d32a472e0359b8 100644 (file)
@@ -95,7 +95,7 @@ public sealed class HandTeleporterSystem : EntitySystem
             var timeout = EnsureComp<PortalTimeoutComponent>(user);
             timeout.EnteredPortal = null;
             component.FirstPortal = Spawn(component.FirstPortalPrototype, Transform(user).Coordinates);
-            _adminLogger.Add(LogType.EntitySpawn, LogImpact.Low, $"{ToPrettyString(user):player} opened {ToPrettyString(component.FirstPortal.Value)} at {Transform(component.FirstPortal.Value).Coordinates} using {ToPrettyString(uid)}");
+            _adminLogger.Add(LogType.EntitySpawn, LogImpact.High, $"{ToPrettyString(user):player} opened {ToPrettyString(component.FirstPortal.Value)} at {Transform(component.FirstPortal.Value).Coordinates} using {ToPrettyString(uid)}");
             _audio.PlayPvs(component.NewPortalSound, uid);
         }
         else if (Deleted(component.SecondPortal))
@@ -113,7 +113,7 @@ public sealed class HandTeleporterSystem : EntitySystem
             var timeout = EnsureComp<PortalTimeoutComponent>(user);
             timeout.EnteredPortal = null;
             component.SecondPortal = Spawn(component.SecondPortalPrototype, Transform(user).Coordinates);
-            _adminLogger.Add(LogType.EntitySpawn, LogImpact.Low, $"{ToPrettyString(user):player} opened {ToPrettyString(component.SecondPortal.Value)} at {Transform(component.SecondPortal.Value).Coordinates} linked to {ToPrettyString(component.FirstPortal!.Value)} using {ToPrettyString(uid)}");
+            _adminLogger.Add(LogType.EntitySpawn, LogImpact.High, $"{ToPrettyString(user):player} opened {ToPrettyString(component.SecondPortal.Value)} at {Transform(component.SecondPortal.Value).Coordinates} linked to {ToPrettyString(component.FirstPortal!.Value)} using {ToPrettyString(uid)}");
             _link.TryLink(component.FirstPortal!.Value, component.SecondPortal.Value, true);
             _audio.PlayPvs(component.NewPortalSound, uid);
         }
@@ -132,7 +132,7 @@ public sealed class HandTeleporterSystem : EntitySystem
             portalStrings += " and ";
         portalStrings += ToPrettyString(component.SecondPortal);
         if (portalStrings != "")
-            _adminLogger.Add(LogType.EntityDelete, LogImpact.Low, $"{ToPrettyString(user):player} closed {portalStrings} with {ToPrettyString(uid)}");
+            _adminLogger.Add(LogType.EntityDelete, LogImpact.High, $"{ToPrettyString(user):player} closed {portalStrings} with {ToPrettyString(uid)}");
 
         // Clear both portals
         if (!Deleted(component.FirstPortal))
index eafcf4dc27c3a70ba33277b4efe4ccef8f392d06..9f0d6a86f5a40b45dbf4a5bcf599744360cfd6de 100644 (file)
@@ -4,8 +4,8 @@
 [Serializable]
 public enum LogImpact : sbyte
 {
-    Low = -1,
-    Medium = 0,
-    High = 1,
-    Extreme = 2 // Nar'Sie just dropped
+    Low = -1, // General logging
+    Medium = 0, // Has impact on the round but not necessary for admins to be notified of
+    High = 1, // Notable logs that come up in normal gameplay; new players causing these will pop up as admin alerts!
+    Extreme = 2 // Irreversible round-impacting logs admins should always be notified of, OR big admin actions!!
 }
index a868d0e38426962d00cacbdcb5502b7b6c7828db..321a89d591f26a8c74bdce35533f1dd65e736941 100644 (file)
@@ -459,4 +459,9 @@ public enum LogType
     /// A player was selected or assigned antag status
     /// </summary>
     AntagSelection = 99,
+
+    /// <summary>
+    /// Logs related to botany, such as planting and harvesting crops
+    /// </summary>
+    Botany = 100,
 }
index 0d7c926f76397618ef66b8d665bde99edb5182bd..f2afbe2f5180a3e0c06e9c39c777c549c23ba908 100644 (file)
@@ -123,7 +123,7 @@ public abstract class SharedAnomalySystem : EntitySystem
         if (HasComp<AnomalySupercriticalComponent>(uid))
             return;
 
-        AdminLog.Add(LogType.Anomaly, LogImpact.Extreme, $"Anomaly {ToPrettyString(uid)} began to go supercritical.");
+        AdminLog.Add(LogType.Anomaly, LogImpact.High, $"Anomaly {ToPrettyString(uid)} began to go supercritical.");
         if (_net.IsServer)
             Log.Info($"Anomaly is going supercritical. Entity: {ToPrettyString(uid)}");
 
index 862456ddfdd9266cdb3d4d11f53fb7bb95a7ba21..f760f3418f3e391239781abf20c46538f7974a50 100644 (file)
@@ -39,4 +39,11 @@ public sealed partial class CCVars
 
     public static readonly CVarDef<string> AdminLogsServerName =
         CVarDef.Create("adminlogs.server_name", "unknown", CVar.SERVERONLY);
+
+    /// <summary>
+    /// Any session below this playtime will send an admin alert whenever they cause a LogImpact.High log.
+    /// Set to -1 to disable.
+    /// </summary>
+    public static readonly CVarDef<int> AdminLogsHighLogPlaytime =
+        CVarDef.Create("adminlogs.high_log_playtime", 5, CVar.SERVERONLY);
 }
index 815760626d985934ed3687a9eaca734c7a7991ef..a1f5ec2a1c0743055855840ae4ca9c37069b21d5 100644 (file)
@@ -361,7 +361,7 @@ namespace Content.Shared.Cuffs
                         ("otherName", Identity.Name(target, EntityManager, user))), user, user);
                     _popup.PopupClient(Loc.GetString("handcuff-component-cuff-by-other-success-message",
                         ("otherName", Identity.Name(user, EntityManager, target))), target, target);
-                    _adminLog.Add(LogType.Action, LogImpact.Medium,
+                    _adminLog.Add(LogType.Action, LogImpact.High,
                         $"{ToPrettyString(user):player} has cuffed {ToPrettyString(target):player}");
                 }
             }
@@ -647,7 +647,7 @@ namespace Content.Shared.Cuffs
             if (!_doAfter.TryStartDoAfter(doAfterEventArgs))
                 return;
 
-            _adminLog.Add(LogType.Action, LogImpact.Low, $"{ToPrettyString(user)} is trying to uncuff {ToPrettyString(target)}");
+            _adminLog.Add(LogType.Action, LogImpact.High, $"{ToPrettyString(user):player} is trying to uncuff {ToPrettyString(target):subject}");
 
             var popupText = user == target
                 ? "cuffable-component-start-uncuffing-self-observer"
@@ -726,12 +726,12 @@ namespace Content.Shared.Cuffs
                 {
                     _popup.PopupEntity(Loc.GetString("cuffable-component-remove-cuffs-by-other-success-message",
                         ("otherName", Identity.Name(user.Value, EntityManager, user))), target, target);
-                    _adminLog.Add(LogType.Action, LogImpact.Medium,
+                    _adminLog.Add(LogType.Action, LogImpact.High,
                         $"{ToPrettyString(user):player} has successfully uncuffed {ToPrettyString(target):player}");
                 }
                 else
                 {
-                    _adminLog.Add(LogType.Action, LogImpact.Medium,
+                    _adminLog.Add(LogType.Action, LogImpact.High,
                         $"{ToPrettyString(user):player} has successfully uncuffed themselves");
                 }
             }
index 5928b3871ff151e89c87a7453dcdb799776837fd..b389d672757f2c98b182be30697ec5ac765682be 100644 (file)
@@ -1,5 +1,7 @@
 using Content.Shared.Database;
+using Content.Shared.Humanoid;
 using Content.Shared.Mobs.Components;
+using Robust.Shared.Player;
 
 namespace Content.Shared.Mobs.Systems;
 
@@ -110,8 +112,10 @@ public partial class MobStateSystem
         var ev = new MobStateChangedEvent(target, component, oldState, newState, origin);
         OnStateChanged(target, component, oldState, newState);
         RaiseLocalEvent(target, ev, true);
-        _adminLogger.Add(LogType.Damaged, oldState == MobState.Alive ? LogImpact.Low : LogImpact.Medium,
-            $"{ToPrettyString(target):user} state changed from {oldState} to {newState}");
+        if (origin != null && HasComp<ActorComponent>(origin) && HasComp<ActorComponent>(target) && oldState < newState)
+            _adminLogger.Add(LogType.Damaged, LogImpact.High, $"{ToPrettyString(origin):player} caused {ToPrettyString(target):player} state to change from {oldState} to {newState}");
+        else
+            _adminLogger.Add(LogType.Damaged, oldState == MobState.Alive ? LogImpact.Low : LogImpact.Medium, $"{ToPrettyString(target):user} state changed from {oldState} to {newState}");
         Dirty(target, component);
     }
 
index d624bc512eb2a9a8a01470055df42a5a256f0deb..583c81d680e96ce2466a35fb70c8439de8b90b4c 100644 (file)
@@ -251,14 +251,14 @@ public abstract class SharedRoleSystem : EntitySystem
         else
         {
             var error = $"The Character Window of {_minds.MindOwnerLoggingString(comp)} potentially did not update immediately : session error";
-            _adminLogger.Add(LogType.Mind, LogImpact.High, $"{error}");
+            _adminLogger.Add(LogType.Mind, LogImpact.Medium, $"{error}");
         }
 
         if (comp.OwnedEntity is null)
         {
             Log.Error($"{ToPrettyString(mind)} does not have an OwnedEntity!");
             _adminLogger.Add(LogType.Mind,
-                LogImpact.High,
+                LogImpact.Medium,
                 $"Role Type of {ToPrettyString(mind)} changed to {roleTypeId}");
             return;
         }
index ee40599493fd105044105e8f79961f47362a7fc9..3645b5a0b93150447d4739ea8774fd6bccc4f75e 100644 (file)
@@ -339,7 +339,7 @@ public abstract class SharedStrippableSystem : EntitySystem
         RaiseLocalEvent(item, new DroppedEvent(user), true); // Gas tank internals etc.
 
         _handsSystem.PickupOrDrop(user, item, animateUser: stealth, animate: !stealth);
-        _adminLogger.Add(LogType.Stripping, LogImpact.Medium, $"{ToPrettyString(user):actor} has stripped the item {ToPrettyString(item):item} from {ToPrettyString(target):target}'s {slot} slot");
+        _adminLogger.Add(LogType.Stripping, LogImpact.High, $"{ToPrettyString(user):actor} has stripped the item {ToPrettyString(item):item} from {ToPrettyString(target):target}'s {slot} slot");
     }
 
     /// <summary>
@@ -544,7 +544,7 @@ public abstract class SharedStrippableSystem : EntitySystem
 
         _handsSystem.TryDrop(target, item, checkActionBlocker: false, handsComp: target.Comp);
         _handsSystem.PickupOrDrop(user, item, animateUser: stealth, animate: !stealth, handsComp: user.Comp);
-        _adminLogger.Add(LogType.Stripping, LogImpact.Medium, $"{ToPrettyString(user):actor} has stripped the item {ToPrettyString(item):item} from {ToPrettyString(target):target}'s hands");
+        _adminLogger.Add(LogType.Stripping, LogImpact.High, $"{ToPrettyString(user):actor} has stripped the item {ToPrettyString(item):item} from {ToPrettyString(target):target}'s hands");
 
         // Hand update will trigger strippable update.
     }
index c3d35c97395efea1e49083bffb855239d2881f0a..704d96cc15f117fc228012d0b566aeeea668167d 100644 (file)
@@ -49,7 +49,7 @@ chat-manager-dead-channel-name = DEAD
 chat-manager-admin-channel-name = ADMIN
 
 chat-manager-rate-limited = You are sending messages too quickly!
-chat-manager-rate-limit-admin-announcement = Player { $player } breached chat rate limits. Watch them if this is a regular occurence.
+chat-manager-rate-limit-admin-announcement = Rate limit warning: { $player }
 
 ## Speech verbs for chat
 
index de7be63d2b850c47bffc63dbce462958416d7077..0df1008834601caef59ec20e22fabe5ffeb2777c 100644 (file)
   noun: seeds-noun-seeds
   displayName: seeds-killertomato-display-name
   plantRsi: Objects/Specific/Hydroponics/tomatokiller.rsi
+  plantLogImpact: High
+  harvestLogImpact: High
   packetPrototype: KillerTomatoSeeds
   productPrototypes:
     - MobTomatoKiller
   displayName: seeds-deathnettle-display-name
   plantRsi: Objects/Specific/Hydroponics/death_nettle.rsi
   packetPrototype: DeathNettleSeeds
+  plantLogImpact: High
+  harvestLogImpact: High
   productPrototypes:
     - DeathNettle
   lifespan: 25
index 02e141826cb8f3127425a03724fdfe75bfef7e67..f97322a9fab2ac88db07263c8bc5d0f56e05b36c 100644 (file)
@@ -2,26 +2,29 @@
   id: MeatSpike
   start: start
   graph:
-    - node: start
-      actions:
-        - !type:DeleteEntity {}
-      edges:
-        - to: MeatSpike
-          completed:
-            - !type:SnapToGrid
-              southRotation: true
-          steps:
-            - material: Steel
-              amount: 15
-              doAfter: 2
-    - node: MeatSpike
-      entity: KitchenSpike
-      edges:
-        - to: start
-          completed:
-            - !type:SpawnPrototype
-              prototype: SheetSteel1
-              amount: 15
-          steps:
-            - tool: Screwing
-              doAfter: 1
+  - node: start
+    actions:
+    - !type:DeleteEntity {}
+    edges:
+    - to: MeatSpike
+      completed:
+      - !type:AdminLog # Needs a log for start of attempt in addition to the completion log
+        message: "Construction"
+        impact: High
+      - !type:SnapToGrid
+        southRotation: true
+      steps:
+      - material: Steel
+        amount: 15
+        doAfter: 2
+  - node: MeatSpike
+    entity: KitchenSpike
+    edges:
+    - to: start
+      completed:
+      - !type:SpawnPrototype
+        prototype: SheetSteel1
+        amount: 15
+      steps:
+      - tool: Screwing
+        doAfter: 1
index 33aa50e1c16b5032dfbd6392879cc8d3f7fbc6bb..02e32b18b86347a6ffd7e170c0b1fdb7c4ba11b0 100644 (file)
@@ -6,6 +6,9 @@
       edges:
         - to: grille
           completed:
+            - !type:AdminLog # Needs a log for start of attempt in addition to the completion log
+              message: "Construction"
+              impact: High
             - !type:SnapToGrid
               southRotation: true
           steps:
index 51a1f9905e030f42781da9e428be5236e0b1b5e5..a434e707293b0776771e47086a1cd7451213ba9f 100644 (file)
@@ -6,6 +6,10 @@
     entity: ShardGlass
     edges:
     - to: icon
+      completed:
+      - !type:AdminLog
+        message: "Construction"
+        impact: High
       steps:
       - material: Cloth
         amount: 1
   - node: start
     edges:
     - to: icon
+      completed:
+      - !type:AdminLog
+        message: "Construction"
+        impact: High
       steps:
       - tag: GlassShard
         name: glass shard
     entity: ShardGlassReinforced
     edges:
     - to: icon
+      completed:
+      - !type:AdminLog
+        message: "Construction"
+        impact: High
       steps:
       - material: Cloth
         amount: 1
   - node: start
     edges:
     - to: icon
+      completed:
+      - !type:AdminLog
+        message: "Construction"
+        impact: High
       steps:
       - tag: ReinforcedGlassShard
         name: reinforced glass shard
     entity: ShardGlassPlasma
     edges:
     - to: icon
+      completed:
+      - !type:AdminLog
+        message: "Construction"
+        impact: High
       steps:
       - material: Cloth
         amount: 1
   - node: start
     edges:
     - to: icon
+      completed:
+      - !type:AdminLog
+        message: "Construction"
+        impact: High
       steps:
       - tag: PlasmaGlassShard
         name: plasma glass shard
     entity: ShardGlassUranium
     edges:
     - to: icon
+      completed:
+      - !type:AdminLog
+        message: "Construction"
+        impact: High
       steps:
       - material: Cloth
         amount: 1
   - node: start
     edges:
     - to: icon
+      completed:
+      - !type:AdminLog
+        message: "Construction"
+        impact: High
       steps:
       - tag: UraniumGlassShard
         name: uranium glass shard
index 3d65c13fe268da1c1cb092dce1831ccee67caf07..d80df72dba9608c1284d1606bfb4a09350662ffb 100644 (file)
@@ -5,6 +5,10 @@
     - node: start
       edges:
         - to: spear
+          completed:
+          - !type:AdminLog # Needs a log for start of attempt in addition to the completion log
+            message: "Construction"
+            impact: High
           steps:
             - material: MetalRod
               amount: 2
     - node: start
       edges:
         - to: spear
+          completed:
+          - !type:AdminLog # Needs a log for start of attempt in addition to the completion log
+            message: "Construction"
+            impact: High
           steps:
             - material: MetalRod
               amount: 2
     - node: start
       edges:
         - to: spear
+          completed:
+          - !type:AdminLog # Needs a log for start of attempt in addition to the completion log
+            message: "Construction"
+            impact: High
           steps:
             - material: MetalRod
               amount: 2
     - node: start
       edges:
         - to: spear
+          completed:
+          - !type:AdminLog # Needs a log for start of attempt in addition to the completion log
+            message: "Construction"
+            impact: High
           steps:
             - material: MetalRod
               amount: 2
     - node: start
       edges:
         - to: spear
+          completed:
+          - !type:AdminLog # Needs a log for start of attempt in addition to the completion log
+            message: "Construction"
+            impact: High
           steps:
             - material: Bones
               amount: 4
index cecd031f972cc0cf4bb72583980b11bd925472e8..2469b31c33aa6d1b073a6c3606abef0294658812 100644 (file)
             - tool: Prying
               doAfter: 1
         - to: bat
+          completed:
+          - !type:AdminLog
+            message: "Construction"
+            impact: High
           steps:
             - tool: Slicing
               doAfter: 4