Files
tbd-station-14/Content.Server/Destructible/Thresholds/Behaviors/GibBehavior.cs
SlamBamActionman 43d08100b9 "New player" admin logging improvements (#35961)
* Initial commit

* Adjust a whoooole bunch of logs

* Also spears

* Track going crit

* Review fix

* Review fixes
2025-03-20 20:56:51 +01:00

24 lines
701 B
C#

using Content.Shared.Body.Components;
using Content.Shared.Database;
using JetBrains.Annotations;
namespace Content.Server.Destructible.Thresholds.Behaviors
{
[UsedImplicitly]
[DataDefinition]
public sealed partial class GibBehavior : IThresholdBehavior
{
[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))
{
system.BodySystem.GibBody(owner, _recursive, body);
}
}
}
}