Migrate revenant and PAI shops to use ActionGrant instead of hardcoding them (#40475)

* add intrinsic store, replace revenant store with it.

* migrate PAI and also move to shared where possible

* fix typos and clean up... intrinisic

* oops, hopefully fixes test

* Move to StoreSystem and ActionGrant

* documentation and remove thing

* review

---------

Co-authored-by: Jessica M <jessica@maybe.sh>
Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
This commit is contained in:
Jessica M
2025-12-29 11:39:19 -06:00
committed by Vanessa
co-authored by Jessica M slarticodefast
parent 3c373dbaf2
commit 24e061bd4e
13 changed files with 46 additions and 114 deletions
+11 -5
View File
@@ -1,17 +1,16 @@
using System.Linq;
using Content.Server.Store.Components;
using Content.Shared.UserInterface;
using Content.Shared.FixedPoint;
using Content.Shared.Implants.Components;
using Content.Shared.Interaction;
using Content.Shared.Popups;
using Content.Shared.Stacks;
using Content.Shared.Store.Components;
using JetBrains.Annotations;
using Content.Shared.Store.Events;
using Content.Shared.UserInterface;
using Robust.Shared.Prototypes;
using Robust.Shared.Utility;
using System.Linq;
using Robust.Shared.Timing;
using Content.Shared.Mind;
using Robust.Shared.Utility;
namespace Content.Server.Store.Systems;
@@ -37,6 +36,7 @@ public sealed partial class StoreSystem : EntitySystem
SubscribeLocalEvent<StoreComponent, ComponentStartup>(OnStartup);
SubscribeLocalEvent<StoreComponent, ComponentShutdown>(OnShutdown);
SubscribeLocalEvent<StoreComponent, OpenUplinkImplantEvent>(OnImplantActivate);
SubscribeLocalEvent<StoreComponent, IntrinsicStoreActionEvent>(OnIntrinsicStoreAction);
InitializeUi();
InitializeCommand();
@@ -187,6 +187,12 @@ public sealed partial class StoreSystem : EntitySystem
UpdateUserInterface(null, uid, store);
return true;
}
private void OnIntrinsicStoreAction(Entity<StoreComponent> ent, ref IntrinsicStoreActionEvent args)
{
ToggleUi(args.Performer, ent.Owner, ent.Comp);
}
}
public sealed class CurrencyInsertAttemptEvent : CancellableEntityEventArgs