private void OnDestroy() { BtnPromptController controller = GameObject.Find("UILayer").GetComponentInChildren <BtnPromptController>(true); if (controller) { GameObject.Find("UILayer").GetComponentInChildren <BtnPromptController>(true).SwitchPromptFrom(0); } }
// Use this for initialization void Start() { btnPromptCtrl = GetComponentInChildren <BtnPromptController>(true); cameraMgr = GameObject.Find("EverySceneNeed").GetComponent <CameraManager>(); // btnSettingCtrl = GetComponentInChildren<BtnSettingController>(true); }
// Use this for initialization void Start() { promptController = GameObject.Find("UILayer").GetComponentInChildren <BtnPromptController>(true); }