class MAGES::SceneGraph::GraphData¶
Version 2 of Graph Data.
class GraphData: public ScriptableObject
{
public:
// fields
SceneGraphData;
List< BaseActionData >;
// properties
System.Action OnNodeAdded;
System.Action OnGroupAdded;
System.Action OnNodeMoved;
System.Action OnGroupMoved;
// methods
static GraphData FromSerialized(GraphDataSerialized graphDataSerialized);
static GraphData FromV1(SceneGraphData v1);
static GraphData FromJsonString(string json);
static PortRef GetSpecifiedPort(Node n, PortRef p);
static List<BaseActionData> GetList(Node node, PortRef portRef);
static void AppendList(
object o,
FieldInfo fieldInfo,
int optIdx,
BaseActionData item
);
GraphData ToV1();
void ApplyV1Links();
void RebuildAccelerationStructures();
bool G_IsValid(NodeRef nodeRef);
bool G_IsValid(PortRef portRef);
bool G_IsValid(Link link);
Node G_NodeGet(NodeRef nodeRef);
Group G_GroupGet(NodeRef groupRef);
Group G_NodeGroupGet(NodeRef nodeRef);
bool G_NodeMove(NodeRef nodeRef, Vector2 position);
bool G_GroupMove(NodeRef groupRef, Vector2 position);
NodeRef G_NodeMake(BaseActionData data);
NodeRef G_NodeMake(System.Type actionType, Vector2 position);
bool G_NodePortDel(NodeRef nodeRef, PortRef portRef);
bool G_NodePortAdd(NodeRef nodeRef, PortRef sibling);
NodeRef G_GroupMake(Vector2 position);
bool G_GroupAdd(NodeRef groupRef, NodeRef nodeRef);
bool G_GroupDel(NodeRef groupRef, NodeRef nodeRef);
void G_Add(List nodesToAdd, List linksToAdd);
string G_ToJsonString();
void G_FromJsonString(string json);
List GetGroups();
List GetNodes();
List GetLinks();
Link G_LinkMake(PortRef From, PortRef To);
void G_Del(
List nodeRefs,
List linksToRemove = null,
List groupsToRemove = null
);
};