public void AddLine( string lineName, double[] xValues, double[] yValues, Color lineColor, int lineThickness, bool display = true ) { if (allLines.ContainsKey(lineName)) { MonoBehaviour.print("[FAR] [ferramGraph] Error: A Line with that name already exists"); return; } if (xValues.Length != yValues.Length) { MonoBehaviour.print("[FAR] [ferramGraph] Error: X and Y value arrays are different lengths"); return; } var newLine = new ferramGraphLine((int)displayRect.width, (int)displayRect.height); newLine.InputData(xValues, yValues); newLine.SetBoundaries(bounds); newLine.lineColor = lineColor; newLine.lineThickness = lineThickness; newLine.backgroundColor = backgroundColor; newLine.displayInLegend = display; allLines.Add(lineName, newLine); Update(); }
public void AddLine(string lineName) { if (allLines.ContainsKey(lineName)) { MonoBehaviour.print("[FAR] [ferramGraph] Error: A Line with that name already exists"); return; } ferramGraphLine newLine = new ferramGraphLine((int)displayRect.width, (int)displayRect.height); newLine.SetBoundaries(bounds); allLines.Add(lineName, newLine); Update(); }
public void AddLine(string lineName) { if (allLines.ContainsKey(lineName)) { MonoBehaviour.print("Error: A Line with that name already exists"); return; } ferramGraphLine newLine = new ferramGraphLine((int)displayRect.width, (int)displayRect.height); newLine.SetBoundaries(bounds); allLines.Add(lineName, newLine); Update(); }
public void AddLine(string lineName, double[] xValues, double[] yValues, Color lineColor, int lineThickness, bool display) { if (allLines.ContainsKey(lineName)) { MonoBehaviour.print("Error: A Line with that name already exists"); return; } if (xValues.Length != yValues.Length) { MonoBehaviour.print("Error: X and Y value arrays are different lengths"); return; } ferramGraphLine newLine = new ferramGraphLine((int)displayRect.width, (int)displayRect.height); newLine.InputData(xValues, yValues); newLine.SetBoundaries(bounds); newLine.lineColor = lineColor; newLine.lineThickness = lineThickness; newLine.backgroundColor = backgroundColor; newLine.displayInLegend = display; allLines.Add(lineName, newLine); Update(); }