* Push 1 * cleanup + master merge * launchontrigger * A crumb of cleanup --------- Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com>
19 lines
575 B
C#
19 lines
575 B
C#
using Content.Shared.Trigger.Components.Triggers;
|
|
using Content.Shared.Weapons.Ranged.Events;
|
|
|
|
namespace Content.Shared.Trigger.Systems;
|
|
public sealed partial class TriggerOnEmptyGunshotSystem : TriggerOnXSystem
|
|
{
|
|
public override void Initialize()
|
|
{
|
|
base.Initialize();
|
|
|
|
SubscribeLocalEvent<TriggerOnEmptyGunshotComponent, OnEmptyGunShotEvent>(OnEmptyGunShot);
|
|
}
|
|
|
|
private void OnEmptyGunShot(Entity<TriggerOnEmptyGunshotComponent> ent, ref OnEmptyGunShotEvent args)
|
|
{
|
|
Trigger.Trigger(ent.Owner, args.User, ent.Comp.KeyOut);
|
|
}
|
|
}
|