Exemplo n.º 1
0
    void SetInviteButtonText()
    {
        GameObject _inviteButton = GameObjectHelper.GetChildNamedGameObject(gameObject, "InviteButton", true);
        GameObject _awardObject  = GameObjectHelper.GetChildNamedGameObject(_inviteButton, "InviteAward", true);

        if (InviteController.WillRewardInvite())
        {
            _awardObject.SetActive(true);

            _awardObject.GetComponent <Text>().text = string.Format("+{0}", Constants.InviteAwardCoins);
        }
        else
        {
            _awardObject.SetActive(false);
        }
    }