CatStation/Content.Shared/Storage/EntitySystems/StoreAfterFailedInteractSystem.cs
Pieter-Jan Briers 5168b5f3d4
IoC source gen compatibility (#43863)
* IoC source gen compatibility

Can be merged before or after https://github.com/space-wizards/RobustToolbox/pull/6549 doesn't really matter.

* Missed a spot
2026-05-09 03:29:58 +00:00

21 lines
669 B
C#

using Content.Shared.Storage.Components;
using Content.Shared.Storage.Events;
namespace Content.Shared.Storage.EntitySystems;
public sealed partial class StoreAfterFailedInteractSystem : EntitySystem
{
[Dependency] private SharedStorageSystem _storage = default!;
public override void Initialize()
{
base.Initialize();
SubscribeLocalEvent<StoreAfterFailedInteractComponent, StorageInsertFailedEvent>(OnStorageInsertFailed);
}
private void OnStorageInsertFailed(Entity<StoreAfterFailedInteractComponent> ent, ref StorageInsertFailedEvent args)
{
_storage.PlayerInsertHeldEntity(args.Storage, args.Player);
}
}