Toggle getMiniMapToggle(MiniMapToggleType type) { string str = minimaptogglepath + type.ToString(); return this.transform.FindChild(str).GetComponent<Toggle>(); }