Example #1
0
 public void Initialize(string name, string description, string points, string image)
 {
     Debug.Log("Initialize");
     if (nameTextElement != null)
     {
         nameTextElement.text = name;
     }
     if (descriptionTextElement != null)
     {
         descriptionTextElement.text = description;
     }
     if (pointsTextElement != null)
     {
         pointsTextElement.text = points;
     }
     if (achievementsImage != null)
     {
         StartCoroutine(NavigationHelpers.GetSpriteFromUrl(image, AssignSprite));
     }
 }
Example #2
0
    void OnSignInComplete(CallbackResponse <SignInResult> cbr)
    {
#if USEXBOXLIVE
        GameState.Instance.User = new XboxLiveUser(cbr.Result);
#else
        GameState.Instance.User = new DummyUser();
#endif

        GameObject obj = GameObject.Find("GamertagText");
        if (obj != null)
        {
            Text text = obj.GetComponent <Text>();
            if (text != null)
            {
                text.text = cbr.Result.User.Gamertag;
            }
        }

        StartCoroutine(NavigationHelpers.GetSpriteFromUrl(cbr.Result.Profile.GameDisplayPictureResizeUri.ToString(), AssignSprite));

        ToggleLoggedInButtons(true);
    }