diff --git a/Content.Server/GameTicking/GameRules/RuleTraitor.cs b/Content.Server/GameTicking/GameRules/RuleTraitor.cs index 5a2a262641..f6e2602418 100644 --- a/Content.Server/GameTicking/GameRules/RuleTraitor.cs +++ b/Content.Server/GameTicking/GameRules/RuleTraitor.cs @@ -20,9 +20,6 @@ namespace Content.Server.GameTicking.GameRules public class RuleTraitor : GameRule { [Dependency] private readonly IChatManager _chatManager = default!; - [Dependency] private readonly IPlayerManager _playerManager = default!; - [Dependency] private readonly IGameTicker _gameTicker = default!; - [Dependency] private readonly IConfigurationManager _cfg = default!; public override void Added() { diff --git a/Content.Server/Objectives/Interfaces/IObjectivesManager.cs b/Content.Server/Objectives/Interfaces/IObjectivesManager.cs index 3108668cab..84250ed956 100644 --- a/Content.Server/Objectives/Interfaces/IObjectivesManager.cs +++ b/Content.Server/Objectives/Interfaces/IObjectivesManager.cs @@ -8,7 +8,7 @@ namespace Content.Server.Objectives.Interfaces /// /// Returns all objectives the provided mind is valid for. /// - IReadOnlyList GetAllPossibleObjectives(Mind mind); + IEnumerable GetAllPossibleObjectives(Mind mind); /// /// Returns a randomly picked objective the provided mind is valid for. diff --git a/Content.Server/Objectives/ObjectivesManager.cs b/Content.Server/Objectives/ObjectivesManager.cs index 0a8750d3d4..be44b1431a 100644 --- a/Content.Server/Objectives/ObjectivesManager.cs +++ b/Content.Server/Objectives/ObjectivesManager.cs @@ -16,14 +16,14 @@ namespace Content.Server.Objectives [Dependency] private IPrototypeManager _prototypeManager = default!; [Dependency] private IRobustRandom _random = default!; - public List GetAllPossibleObjectives(Mind mind) + public IEnumerable GetAllPossibleObjectives(Mind mind) { - return _prototypeManager.EnumeratePrototypes().Where(objectivePrototype => objectivePrototype.CanBeAssigned(mind)).ToList(); + return _prototypeManager.EnumeratePrototypes().Where(objectivePrototype => objectivePrototype.CanBeAssigned(mind)); } public ObjectivePrototype? GetRandomObjective(Mind mind) { - var objectives = GetAllPossibleObjectives(mind); + var objectives = GetAllPossibleObjectives(mind).ToList(); _random.Shuffle(objectives); //to prevent endless loops