using Content.Server.Power.EntitySystems; using Content.Server.Research.Components; using Content.Shared.Research.Components; namespace Content.Server.Research.Systems; public sealed partial class ResearchSystem { private void InitializeSource() { SubscribeLocalEvent(OnGetPointsPerSecond); } private void OnGetPointsPerSecond(Entity source, ref ResearchServerGetPointsPerSecondEvent args) { if (CanProduce(source)) args.Points += source.Comp.PointsPerSecond; } public bool CanProduce(Entity source) { return source.Comp.Active && this.IsPowered(source, EntityManager); } }