forked from aly/qstbak
20 lines
460 B
C#
20 lines
460 B
C#
namespace Questionable.Controller.Conditions;
|
|
|
|
internal sealed class LevelCondition : StopCondition
|
|
{
|
|
public required int TargetLevel { get; set; }
|
|
|
|
public override bool IsSession => false;
|
|
|
|
public override EStopConditionType Type => EStopConditionType.Level;
|
|
|
|
public override bool Evaluate(StopEvaluationContext context)
|
|
{
|
|
return context.PlayerLevel >= TargetLevel;
|
|
}
|
|
|
|
public override string GetDescription()
|
|
{
|
|
return $"Level {TargetLevel}";
|
|
}
|
|
}
|