private IEnumerator _sendLoginData(string email) { var wwwForm = new WWWForm(); wwwForm.AddField("email", email); var www = new WWW(InfoStorage.Server + InfoStorage.Connect, wwwForm); yield return(www); Debug.Log(InfoStorage.Server + InfoStorage.Connect); if (www.error != null) { yield break; } Debug.Log(www.text); var json = JSON.Parse(www.text); string answer = json["error"]; Debug.Log(answer); if (!answer.Equals("ok")) { yield break; } PlayerPrefs.SetString("email", email); PlayerPrefs.SetInt("auntificated", 1); AnimationAssistant.MoveY(transform, transform.position.y - Screen.height); }
public void Close() { if (!_opened) { return; } _helper.PanelClose(); _opened = false; AnimationAssistant.MoveY(transform, InfoStorage.ClosedPanelPosY); }
public void Open() { if (_opened) { return; } _helper.Increase(); _opened = true; AnimationAssistant.MoveY(transform, InfoStorage.OpenedPanelPosY); }
private IEnumerator _loginFormUpCoroutine() { yield return(new WaitForSeconds(0.5f)); AnimationAssistant.Hide(gameObject.GetComponent <CanvasGroup>()); if (PlayerPrefs.GetInt("auntificated") != 1) { AnimationAssistant.MoveLocalY(_loginForm, 0); } else { AnimationAssistant.MoveY(_loginPanel, InfoStorage.ClosedPanelPosY); } }
public void Escape() { if (_lock) { return; } switch (_context) { case Context.Feedback: AnimationAssistant.MoveY(_feedback, _feedback.transform.position.y - PlayerPrefs.GetFloat("height")); _context = Context.Main; break; case Context.Instagram: AnimationAssistant.MoveY(_instagram, _instagram.transform.position.y - PlayerPrefs.GetFloat("height")); _context = Context.Main; break; } }