Last active
November 27, 2017 14:31
-
-
Save nickyeh97/7c0b8f07af8485d8c7b5e3ba5ce96c9d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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; | |
} | |
GS.DetectGround (); | |
Debug.Log("Trackable " + mTrackableBehaviour.TrackableName + " found"); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment