CatStation/Content.Server/Anomaly/Effects/ExplosionAnomalySystem.cs
Pieter-Jan Briers 5168b5f3d4
IoC source gen compatibility (#43863)
* IoC source gen compatibility

Can be merged before or after https://github.com/space-wizards/RobustToolbox/pull/6549 doesn't really matter.

* Missed a spot
2026-05-09 03:29:58 +00:00

30 lines
907 B
C#

using Content.Server.Explosion.EntitySystems;
using Content.Server.Anomaly.Components;
using Content.Shared.Anomaly.Components;
namespace Content.Server.Anomaly.Effects;
/// <summary>
/// This handles <see cref="ExplosionAnomalyComponent"/>
/// </summary>
public sealed partial class ExplosionAnomalySystem : EntitySystem
{
[Dependency] private ExplosionSystem _boom = default!;
public override void Initialize()
{
base.Initialize();
SubscribeLocalEvent<ExplosionAnomalyComponent, AnomalySupercriticalEvent>(OnSupercritical);
}
private void OnSupercritical(EntityUid uid, ExplosionAnomalyComponent component, ref AnomalySupercriticalEvent args)
{
_boom.QueueExplosion(
uid,
component.ExplosionPrototype,
component.TotalIntensity,
component.Dropoff,
component.MaxTileIntensity
);
}
}