Exemple #1
0
    protected override void OnEnable()
    {
        base.OnEnable();

        SOUND.I.Play(DEF.SND.popup_open);
        _btnInBox.interactable   = true;
        _btnFBLogin.interactable = true;

        if (USER.I.CurProfileTexture != null)
        {
            _imgPhoto.gameObject.SetActive(true);
            _imgPhoto.texture = USER.I.CurProfileTexture;
        }
        _textUserName.text   = USER.I.GetUserInfo().GetName();
        _textUserUID.text    = "UID : " + USER.I.GetUserInfo().GetId().ToString();
        _tgSounds.isOn       = PlayerPrefHelper.GetSoundOn();
        _tgNotification.isOn = PlayerPrefHelper.GetNofiOn();

        if (USER.I.IsGuestLogin)
        {
            _btnSignOut.gameObject.SetActive(false);
            _btnInBox.gameObject.SetActive(true);
            _btnFBLogin.gameObject.SetActive(true);
            _btnFBLogin.interactable = true;
        }
        else
        {
            _btnSignOut.gameObject.SetActive(true);
            _btnInBox.gameObject.SetActive(false);
            _btnFBLogin.gameObject.SetActive(false);
        }
    }
Exemple #2
0
 public void Initialize()
 {
     // 버퍼
     for (int i = 0; i < 20; ++i)
     {
         GameObject go = new GameObject("AudioSource");
         audioBufferDic.Add(go.AddComponent <AudioSource>(), 0);
         go.transform.SetParent(this.transform);
     }
     // Lobby Sound Load
     LoadResourceAudioClipsPackage("Sounds");
     SetSoundOn(PlayerPrefHelper.GetSoundOn());
 }