Version: Unity 6.6 (6000.6)
Language : English
Implement node options
Add custom toolbar actions

Allow ports to connect across types

To allow connecting ports of different types, for example an int port to a float port:

  1. Override the method Graph.IsConnectionAllowed().
  2. Check the output’s data type with output.DataType == typeof(int).
  3. Check the input’s data type with input.DataType == typeof(float).
  4. Return true when conditions match.

Refer to the full example in the IsConnectionAllowed API reference.

Additional resources

Implement node options
Add custom toolbar actions