示例#1
0
文件: GetName.cs 项目: Vatras12/Lab7
 void Start()
 {
     json = new JSONController();
     json.LoadField();
     if (json.item.loggedIn == "true")
     {
         text.text = PlayerPrefs.GetString("USERNAME");
     }
 }
示例#2
0
 public void OnClickLogout()
 {
     json = new JSONController();
     json.LoadField();
     json.item.loggedIn = "false";
     json.item.Name     = "";
     json.SaveField();
     text.text = "None";
     PlayerPrefs.DeleteKey("EMAIL");
     PlayerPrefs.DeleteKey("PASSWORD");
 }
示例#3
0
 public void OnClick()
 {
     json = new JSONController();
     json.LoadField();
     if (json.item.loggedIn == "true")
     {
         SceneManager.LoadScene(3);
     }
     else
     {
         SceneManager.LoadScene(2);
     }
 }
示例#4
0
    void Start()
    {
        json = new JSONController();
        json.LoadField();
        if (string.IsNullOrEmpty(PlayFabSettings.TitleId))
        {
            PlayFabSettings.TitleId = "321";
        }


        if (json.item.loggedIn == "true")
        {
            userEmail    = PlayerPrefs.GetString("EMAIL");
            userPassword = PlayerPrefs.GetString("PASSWORD");
            var requst = new LoginWithEmailAddressRequest {
                Email = userEmail, Password = userPassword
            };
            PlayFabClientAPI.LoginWithEmailAddress(requst, OnLoginSuccess, OnLoginFailureStart);
        }
    }
示例#5
0
 void Start()
 {
     json.LoadField();
     text.text = json.item.Name;
 }
示例#6
0
文件: GetName.cs 项目: Vatras12/Lb3
 void Start()
 {
     json.LoadField();
     InputField1.text = json.item.Name;
     //InputField1.text = PlayerPrefs.GetString(saveNameKey);
 }