mirror of
https://github.com/space-syndicate/space-station-14.git
synced 2026-10-14 12:51:10 +03:00
* Moving into Systems & Components Folders * splitting into API file * Make Method accept null values * small fix
20 lines
566 B
C#
20 lines
566 B
C#
using Content.Shared.Timing.Systems;
|
|
using Content.Shared.Weapons.Ranged.Components;
|
|
|
|
namespace Content.Shared.Weapons.Ranged.Systems;
|
|
|
|
public sealed partial class UseDelayOnShootSystem : EntitySystem
|
|
{
|
|
[Dependency] private UseDelaySystem _delay = default!;
|
|
|
|
public override void Initialize()
|
|
{
|
|
base.Initialize();
|
|
SubscribeLocalEvent<UseDelayOnShootComponent, GunShotEvent>(OnUseShoot);
|
|
}
|
|
|
|
private void OnUseShoot(Entity<UseDelayOnShootComponent> ent, ref GunShotEvent args)
|
|
{
|
|
_delay.TryResetDelay(ent.Owner);
|
|
}
|
|
}
|