2022-01-13 09:53:50 -05:00
|
|
|
|
using System;
|
|
|
|
|
|
using Content.Server.Objectives.Interfaces;
|
|
|
|
|
|
using Content.Server.Traitor;
|
|
|
|
|
|
using Robust.Shared.Serialization.Manager.Attributes;
|
|
|
|
|
|
using Robust.Shared.GameObjects;
|
|
|
|
|
|
using Content.Server.GameTicking.Rules;
|
|
|
|
|
|
|
|
|
|
|
|
namespace Content.Server.Objectives.Requirements
|
|
|
|
|
|
{
|
|
|
|
|
|
[DataDefinition]
|
2022-02-16 00:23:23 -07:00
|
|
|
|
public sealed class MultipleTraitorsRequirement : IObjectiveRequirement
|
2022-01-13 09:53:50 -05:00
|
|
|
|
{
|
|
|
|
|
|
[DataField("traitors")]
|
|
|
|
|
|
private readonly int _requiredTraitors = 2;
|
|
|
|
|
|
|
|
|
|
|
|
public bool CanBeAssigned(Mind.Mind mind)
|
|
|
|
|
|
{
|
|
|
|
|
|
return EntitySystem.Get<TraitorRuleSystem>().TotalTraitors >= _requiredTraitors;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|