private void MenuReadyEvent(powerbeatsvr.Menu menu) { Button test = null; foreach (var button in FindObjectsOfType <Button>()) { if (button.name == "Official") { Logger.Instance.Log("Found the button.", Logger.LogSeverity.DEBUG); test = button; break; } } if (test != null) { GameObject btnCont = Instantiate(test.gameObject); btnCont.transform.parent = parent.transform; var t = btnCont.GetComponent <RectTransform>(); t.localPosition = new Vector3(0, 2, 0); t.localScale = new Vector3(10, 10, 10); } }
private void OnMenuReady(powerbeatsvr.Menu menu) { //PBUtil.Instance.PrintButtons(); //PBUtil.Instance.PrintCameras(); }