Creating Custom Nodes in Script Canvas

Creating custom nodes in Script Canvas offers you maximum control and flexibility with the functionality of the node. You might wish to create a custom node in the following scenarios:

  • When your node has state, time, or latent results.
  • When creating complex nodes.
  • When you need control over the node’s topology.
  • When you want to reflect your own C++ free functions.

To make the process of creating a custom node easier, Script Canvas uses a templated, automatic code generation system called AzAutoGen to significantly reduce the amount of “boilerplate code” you need to write just to get a node up and running. Using AzAutoGen allows the developer to immediately focus on the functionality of the new node, since the code required for the node to show up in the Node Palette is already there.

The following four steps are required to create a custom node:

  1. Create a code generation XML file.
  2. Create the C++ files for your node.
  3. Add these files to CMake.
  4. Register your new node.

For a better understanding of creating custom nodes, we recommend reading following


Custom Nodeable NodesHow to create custom Script Canvas Nodeable Nodes in Open 3D Engine (O3DE).
Custom Free Function NodesHow to create custom Script Canvas Free Function Nodes in Open 3D Engine (O3DE).
Node Definition ReferenceReference guide for Script Canvas node definitions.
Dynamic Data SlotsUse dynamic data slots to enable a single Script Canvas node to process a variety of data types in Open 3D Engine (O3DE).