Class CustomCondition
Inheritance
CustomCondition
Assembly: Serenity.UnityAchievements.Infrastructure.dll
Syntax
[AchievementConditionCategory(AchievementConditionCategory.Code)]
public class CustomCondition : AchievementCondition
Constructors
CustomCondition()
Creates an unauthored condition, as Unity's polymorphic serializer does.
Declaration
CustomCondition(string)
Creates a condition delegating to a project-supplied rule.
Declaration
public CustomCondition(string conditionTypeName)
Parameters
| Type |
Name |
Description |
| string |
conditionTypeName |
The type name of the rule to delegate to.
|
Properties
ConditionTypeName
The type name of the project-supplied rule.
Declaration
public string ConditionTypeName { get; }
Property Value
DisplayName
Declaration
public override string DisplayName { get; }
Property Value
NeedsTick
Polled, because a project-supplied rule reads whatever it likes and this node cannot
know what would notify it. A custom rule that only cares about a signal is cheap to ask.
Declaration
public override bool NeedsTick { get; }
Property Value
Methods
Describe(bool)
Declaration
public override string Describe(bool isNested)
Parameters
| Type |
Name |
Description |
| bool |
isNested |
|
Returns
GetProgress(in AchievementEvaluationContext)
Declaration
public override AchievementConditionProgress GetProgress(in AchievementEvaluationContext context)
Parameters
Returns
IsMet(in AchievementEvaluationContext)
Declaration
public override bool IsMet(in AchievementEvaluationContext context)
Parameters
Returns
Reset()
Declaration
public override void Reset()
Validate()
Declaration
public override string Validate()
Returns
ValidateAgainst(IAchievementCustomConditionResolver)
Validates against a live resolver, which is the only way to tell a renamed or deleted
type from one that simply is not loaded yet.
Declaration
public string ValidateAgainst(IAchievementCustomConditionResolver resolver)
Parameters
Returns
| Type |
Description |
| string |
What is wrong, or null when the node is valid.
|
ValidateCustomRule(IAchievementCustomConditionResolver)
Declaration
public override string ValidateCustomRule(IAchievementCustomConditionResolver resolver)
Parameters
Returns