# DeepSearch

From Unify Community Wiki

**This article is a stub.**

You can help UnifyWiki by expanding it.

## JS Script

static function deepSearch (t : Transform, s : String) : Transform { var dt : Transform = t.Find (s); if (dt) return dt; else { for (var child : Transform in t) { dt = deepSearch (child, s); if (dt) return dt; } } return null; }

## C# Script

static public Transform deepSearch(Transform t, string s) { Transform dt = t.Find(s); if (dt != null) return dt; else { foreach (Transform child in t) { dt = deepSearch(child, s); if (dt != null) return dt; } } return null; }