public void TweetManage()
    {
        string clearText = string.Empty;
        string rankText  = rankData.findRank(resultStruct.score).rankAlphabet;

        switch (resultStruct.clearType)
        {
        case ClearType.Failed:
            clearText = "クリア出来なかったよ...";
            break;

        case ClearType.Clear:
            clearText = "クリアしたよ!";
            break;

        case ClearType.ExClear:
            clearText = "Exクリアしたよ!";
            break;

        case ClearType.FullCombo:
            clearText = "フルコンボしたよ!!";
            break;

        case ClearType.Prefect:
            clearText = "パーフェクトしたよ!!!";
            break;
        }

        string sentence       = "「{0}」の難易度「{1}」をランク「{2}」で{3} ";
        string formatSentence = string.Format(sentence, resultStruct.musicTitle, resultStruct.difficulty, rankText, clearText);

        StartCoroutine(TweetWithScreenShot.TweetManager.TweetWithScreenShot(formatSentence));
    }
Example #2
0
    public void SetScoreText()
    {
        if (musicData.selectMusicElement == 0)
        {
            hiScoreText.SetText("-------");
            clearRateText.SetText("--.-%");
            clearTypeText.SetText(string.Empty);
            rankText.SetText(string.Empty);
        }
        else
        {
            MusicInfoStruct musicInfo = musicData.GetSelectingMusicStruct();

            int bestScore = musicInfo.score[(int)musicData.selectingDif];

            hiScoreText.text = bestScore.ToString("D7");

            ClearTypeStruct clearType = musicData.clearTypeData.clearTypes[musicInfo.clearType[(int)musicData.selectingDif]];
            clearTypeText.SetText(clearType.clearName);
            clearTypeText.colorGradientPreset = clearType.colorGradient;
            clearTypeText.color = clearType.clearColor;

            if (musicInfo.clearRate[(int)musicData.selectingDif] == null)
            {
                clearRateText.SetText("--.-%");
                rankText.SetText(string.Empty);
            }
            else
            {
                clearRateText.SetText("{0:1}%", (float)musicInfo.clearRate[(int)musicData.selectingDif]);

                RankStruct rank = rankData.findRank(bestScore);
                rankText.SetText(rank.rankAlphabet);
                rankText.colorGradientPreset = rank.colorGradient;
                rankText.color = rank.rankColor;
            }
        }
    }