Collapsing to Macro
In addition to collapsing to a Collapsed Graph or Function, you can also collapse nodes to a Macro. The best way to think of a Macro is that it allows you to take several nodes that are connected and consolidate them into a single node that does everything you need it to do all in one. It is particularly useful for anything that you do frequently, like a complex math equation.
See below for steps on collapsing nodes to a Macro.
- With the nodes you wish to collapse selected, Right-click on a node and select Collapse to Macro.
- A new Macro node will be created, which you can re-name via the MyBlueprint window by pressing F2 on it.
- You can open the Macro by Double-clicking on it.
Click image for full size.
As with the other method of collapsing nodes, you can add Input or Output pins as needed.
Here is our Event Graph which implements the Macro with the additional pins.
- By Right-clicking on your Macro, you can select Expand Node to revert the collpasing of the nodes.
For more information about Macros, see the Macros documentation.