using Content.Shared.Objectives.Components; namespace Content.Server._Sunrise.PlanetPrison; public sealed class EscapePrisonConditionSystem : EntitySystem { [Dependency] private readonly PlanetPrisonSystem _planetPrisonSystem = default!; public override void Initialize() { base.Initialize(); SubscribeLocalEvent(OnGetProgress); } private void OnGetProgress(EntityUid uid, EscapePrisonConditionComponent comp, ref ObjectiveGetProgressEvent args) { args.Progress = _planetPrisonSystem.PrisonerEscaped(args.MindId) ? 1f : 0f; } }