コード例 #1
0
    // Start is called before the first frame update
    void Start()
    {
        returnButton.gameObject.SetActive(true);
        game       = new GamesPlayed();
        helper     = (HelperScript)FindObjectOfType(typeof(HelperScript));
        httpServer = helper.GetHttpServer();
        player     = helper.GetPlayer();
        StartCoroutine(LoadImage(player.BlobUri, avatar));
        game.playerId     = player.Id;
        nicknameText.text = player.NickName;
        switch (player.TotalScore)
        {
        case int n when(n < 50):
            StartCoroutine(LoadImage(medals[0], lvl));

            break;

        case int n when(n > 49 && n < 500):
            StartCoroutine(LoadImage(medals[1], lvl));

            break;

        case int n when(n > 499):
            StartCoroutine(LoadImage(medals[2], lvl));

            break;
        }
    }
コード例 #2
0
ファイル: Login.cs プロジェクト: arxeus99/ClicyCratesClient
 void Start()
 {
     gameManager       = (HelperScript)FindObjectOfType(typeof(HelperScript));
     httpServerAddress = gameManager.GetHttpServer();
     this.semaforo     = 0;
     this.loged        = false;
 }
コード例 #3
0
    // Start is called before the first frame update
    void Start()
    {
        gameManager = (HelperScript)FindObjectOfType(typeof(HelperScript));
        httpServer  = gameManager.GetHttpServer();
        player      = gameManager.GetPlayer();
        StartCoroutine(LoadImage(player.BlobUri));
        nickname.text = player.NickName;
        UpdateState("1", player.Id);
        GetGame();

        foreach (GamesPlayed g in games.games)
        {
            scores.text = scores.text + "\n" + g.playerId.Substring(0, 3) + " || " + g.dateStarted + " || " + g.dateEnded + " || " + g.difficult + " || " + g.score;
        }
    }
コード例 #4
0
ファイル: Profile.cs プロジェクト: arxeus99/ClicyCratesClient
 // Start is called before the first frame update
 void Start()
 {
     gameManager = (HelperScript)FindObjectOfType(typeof(HelperScript));
     httpServer  = gameManager.GetHttpServer();
     player      = gameManager.GetPlayer();
     GetGame();
     firstName.text = player.FirstName;
     lastName.text  = player.LastName;
     nickName.text  = player.NickName;
     city.text      = player.City;
     birthDate.text = player.BirthDate;
     foreach (GamesPlayed g in games.games)
     {
         gamesPlayed.text = gamesPlayed.text + "\n" + g.playerId.Substring(0, 3) + " || " + g.dateStarted + " || " + g.dateEnded + " || " + g.difficult + " || " + g.score;
     }
 }
コード例 #5
0
 // Start is called before the first frame update
 void Start()
 {
     gameManager = (HelperScript)FindObjectOfType(typeof(HelperScript));
     httpServer  = gameManager.GetHttpServer();
     StartCoroutine(LoadImage());
 }