Returns the weight associated with the behavior specified by subscript syntax.
- iOS 10.0+
- macOS 10.12+
- Mac Catalyst 13.0+
- tvOS 10.0+
An individual behavior already included in the composite behavior’s set of behaviors.
The weight applied to that behavior’s influence on an agent’s speed and direction, or
0 if that behavior is not in the composite behavior.
This method is equivalent to the
weight(for:) method, but allows access using subscript syntax.