I have a common use case of instantiating graph assets with particular nodes and requiring those nodes to exist at runtime while not exposing them via the search window so that someone cannot add additional instances to the graph.
I add a [Tags("Hidden")] so that the node doesn't show up in the search, and just do a Graph.AddNode() in the class constructor of my Graph, but there's nothing to prevent someone from deleting it in the canvas.
This would probably be another field for NodeAttribute and used solely by the editor to prevent delete actions on that node.
I have a common use case of instantiating graph assets with particular nodes and requiring those nodes to exist at runtime while not exposing them via the search window so that someone cannot add additional instances to the graph.
I add a
[Tags("Hidden")]
so that the node doesn't show up in the search, and just do aGraph.AddNode()
in the class constructor of my Graph, but there's nothing to prevent someone from deleting it in the canvas.This would probably be another field for
NodeAttribute
and used solely by the editor to prevent delete actions on that node.