mirror of
https://github.com/DeltaV-Station/Delta-v.git
synced 2026-09-30 08:07:28 +00:00
20 lines
525 B
C#
20 lines
525 B
C#
using Content.Shared.Damage;
|
|
|
|
namespace Content.Server.Armor
|
|
{
|
|
public sealed class ArmorSystem : EntitySystem
|
|
{
|
|
public override void Initialize()
|
|
{
|
|
base.Initialize();
|
|
|
|
SubscribeLocalEvent<ArmorComponent, DamageModifyEvent>(OnDamageModify);
|
|
}
|
|
|
|
private void OnDamageModify(EntityUid uid, ArmorComponent component, DamageModifyEvent args)
|
|
{
|
|
args.Damage = DamageSpecifier.ApplyModifierSet(args.Damage, component.Modifiers);
|
|
}
|
|
}
|
|
}
|