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

ChangeKind

enumeration

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

Categories of change that can be reported on a graph or state machine element.

ChangeKind is a bit-flag enum, so a single value can describe multiple categories of change at once. Combine values with | and test them with & or Enum.HasFlag. A value of ChangeKind.None means no change categories are set.

Combine flags with the bitwise-or operator, and test them with bitwise-and or <see cref="Enum.HasFlag" />:

 ChangeKind kinds = ChangeKind.Added | ChangeKind.Data;

if ((kinds & ChangeKind.Added) != 0) { /* newly added */ } if (kinds.HasFlag(ChangeKind.Data)) { /* data changed */ }

Properties

Property Description
NoneNo change categories.
LayoutThe position or dimension of the element changed.
StyleThe visual style (color, etc.) of the element changed.
DataModel data (for example, an inspectable field) changed.
TopologyGraph or state machine topology changed; typically, a wire or transition was connected or disconnected.
GroupingGrouping of variables in the blackboard changed.
AddedThe element was added to the graph or state machine.
RemovedThe element was removed from the graph or state machine.
PortChangedA port on the node changed; inspect ChangedNode.ChangedPorts for details.
RecreateViewThe view for the element must be torn down and recreated (for example, a variable node flipped between Get and Set).