mirror of
https://github.com/space-syndicate/space-station-14.git
synced 2026-10-09 18:31:17 +03:00
* added * remove * last changes * remove more old stuff * rename * rename --------- Co-authored-by: iaada <iaada@users.noreply.github.com>
19 lines
666 B
C#
19 lines
666 B
C#
using Content.Shared.Damage.Components;
|
|
using Content.Shared.StatusEffectNew;
|
|
|
|
namespace Content.Shared.Damage.Systems;
|
|
|
|
public sealed class DamageModifierStatusEffectSystem : EntitySystem
|
|
{
|
|
public override void Initialize()
|
|
{
|
|
base.Initialize();
|
|
|
|
SubscribeLocalEvent<DamageModifierStatusEffectComponent, StatusEffectRelayedEvent<DamageModifyEvent>>(OnDamageModifyStatus);
|
|
}
|
|
|
|
private void OnDamageModifyStatus(Entity<DamageModifierStatusEffectComponent> status, ref StatusEffectRelayedEvent<DamageModifyEvent> args)
|
|
{
|
|
args.Args.Damage = DamageSpecifier.ApplyModifierSet(args.Args.Damage, status.Comp.Modifiers);
|
|
}
|
|
}
|