// Start is called before the first frame update void Start() { adjuster = GameObject.Find("BoundsManager"); leftBound = adjuster.transform.GetChild(1).GetComponent <TextMesh>(); rightBound = adjuster.transform.GetChild(2).GetComponent <TextMesh>(); a = adjuster.transform.GetChild(5).GetComponent <BoundsButton>(); b = adjuster.transform.GetChild(7).GetComponent <BoundsButton>(); a.trackerleft = 0; b.trackerright = 5; }
public void OnMouseDown() { GameObject link = GameObject.Find("MeshRendererTestFive"); MeshTestFive M = link.GetComponent <MeshTestFive>(); // we create a new MeshTestFive? adjuster = GameObject.Find("BoundsManager"); a = adjuster.transform.GetChild(5).GetComponent <BoundsButton>(); b = adjuster.transform.GetChild(7).GetComponent <BoundsButton>(); int x = M.generate(eq, a.getLeft(), b.getRight()); if (x == 1) { MeshTestFive.menu_string = "Invalid bounds"; } }