// Get the scroll node info at the specified point index. // // pointIndex: Index of the point from which you're getting the scroll node info. // SideScrollNodeInfo GetInfoAtPoint(int pointIndex) { if (pointIndex < 0 || pointIndex >= path.Count) { return(defaultNodeInfo); } AutoSideScrollNode node = path [pointIndex].GetComponent <AutoSideScrollNode> (); if (node == null) { return(defaultNodeInfo); } else { return(node.info); } }
// Get the scroll node info at the specified point index. // // pointIndex: Index of the point from which you're getting the scroll node info. // SideScrollNodeInfo GetInfoAtPoint(int pointIndex) { if (pointIndex < 0 || pointIndex >= curve.pointCount) { return(defaultNodeInfo); } BezierPoint[] points = curve.GetAnchorPoints(); AutoSideScrollNode node = points [pointIndex].GetComponent <AutoSideScrollNode> (); if (node == null) { return(defaultNodeInfo); } else { return(node.info); } }