private void OnTrackingFound() { Renderer[] rendererComponents = GetComponentsInChildren <Renderer>(true); Collider[] colliderComponents = GetComponentsInChildren <Collider>(true); // Enable rendering: foreach (Renderer component in rendererComponents) { component.enabled = true; } // Enable colliders: foreach (Collider component in colliderComponents) { component.enabled = true; } a = a + 1; if (a == 1) { GameObject asdobj = GameObject.FindGameObjectWithTag("GameController"); if (asdobj != null) { yoo = asdobj.GetComponent <ObjectDisplay>(); } if (yoo == null) { Debug.Log("Cannot find 'Object Display' script"); } yoo.Display(); } Debug.Log("Trackable " + mTrackableBehaviour.TrackableName + " found"); }