using Content.Shared.Storage.EntitySystems; using Content.Shared.Interaction; using Content.Shared.IgnitionSource.Components; namespace Content.Shared.IgnitionSource.EntitySystems; public sealed class MatchboxSystem : EntitySystem { [Dependency] private readonly MatchstickSystem _match = default!; public override void Initialize() { base.Initialize(); SubscribeLocalEvent(OnInteractUsing, before: [ typeof(SharedStorageSystem) ]); } private void OnInteractUsing(Entity ent, ref InteractUsingEvent args) { if (args.Handled || !TryComp(args.Used, out var matchstick)) return; args.Handled = _match.TryIgnite((args.Used, matchstick), args.User); } }