Version: Unity 6.7 Alpha (6000.7)
LanguageEnglish
  • C#

Condition<T0>

class in Unity.GraphToolkit.Editor

/

Inherits from:Unity.GraphToolkit.Editor.Condition

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Description

The base class for user-accessible conditions holding a value of type T.

Inherit from this class to define a custom condition type. The Condition<T0>.Value field is serialized with the state machine and is displayed and edited in the transition inspector. To read the condition back from an asset, for example in an importer, cast the ICondition to the concrete derived type and read Condition<T0>.Value and Condition<T0>.Comparison. For a condition without a value, derive from Condition instead.

Properties

Property Description
Comparison The comparison operator applied to the condition's value.
DisplayComparisonDropdown Whether the transition inspector displays a dropdown to select the condition's comparison operator.
SupportedComparisons The comparison operators offered by the comparison dropdown.
Value The value of the condition.

Inherited Members

Properties

PropertyDescription
ID The globally unique identifier for this condition.
Rule The rule this condition belongs to, or null when the condition is not part of one.
StateMachine The Condition.StateMachine that contains this condition, or null when the condition is not part of a state machine.
Title The label displayed for the condition in the transition inspector.
Tooltip The text displayed when hovering over the condition in the transition inspector.