private void Awake() { uiMasterControl = gameObject.AddComponent <UIMasterControl>(); audioSourceControl = gameObject.AddComponent <AudioSourceControl>(); GameObject menuBackGroundObj = MenuBackGroundBuilder.buildMenuBack(new Vector3(0, 0, 0)); menuBackGround = menuBackGroundObj.GetComponent <MenuBackGroundCpt>(); }
private void Awake() { CommonData.GameStatus = 0; gameFinshAnimTime = 3f; uiMasterControl = gameObject.AddComponent <UIMasterControl>(); audioSourceControl = gameObject.AddComponent <AudioSourceControl>(); audioSourceControl.stopBGMClip(); initData(); }
/// <summary> /// 检测是否开启秘密代码 /// </summary> /// <returns></returns> private bool checkIsOpenSecretCode() { UIMasterControl uiControl = GetComponent <UIMasterControl>(); if (uiControl != null) { bool isOpen = false; if (uiControl.isShowUI(UIEnum.MenuMainUI) || uiControl.isShowUI(UIEnum.GameMainUI)) { isOpen = true; } return(isOpen); } else { return(false); } }
private void Start() { uiMasterControl = GetComponent <UIMasterControl>(); }
public void Start() { mUIMasterControl = FindObjectOfType(typeof(UIMasterControl)) as UIMasterControl; }