using Robust.Shared.Map;
using Content.Shared.Medical.SuitSensor;
using Robust.Shared.Timing;
+using Content.Server.PowerCell;
namespace Content.Server.Medical.CrewMonitoring
{
[Dependency] private readonly SharedTransformSystem _xform = default!;
[Dependency] private readonly IGameTiming _gameTiming = default!;
[Dependency] private readonly IMapManager _mapManager = default!;
+ [Dependency] private readonly PowerCellSystem _cell = default!;
public override void Initialize()
{
private void OnUIOpened(EntityUid uid, CrewMonitoringConsoleComponent component, BoundUIOpenedEvent args)
{
+ if (!_cell.TryUseActivatableCharge(uid))
+ return;
+
UpdateUserInterface(uid, component);
}
+using Content.Server.PowerCell;
using Content.Shared.Pinpointer;
using Robust.Server.GameObjects;
public sealed class StationMapSystem : EntitySystem
{
[Dependency] private readonly UserInterfaceSystem _ui = default!;
+ [Dependency] private readonly PowerCellSystem _cell = default!;
public override void Initialize()
{
if (args.Session.AttachedEntity == null)
return;
+ if (!_cell.TryUseActivatableCharge(uid))
+ return;
+
var comp = EnsureComp<StationMapUserComponent>(args.Session.AttachedEntity.Value);
comp.Map = uid;
}