コード例 #1
0
    bool InitialiseScoreIncrementer()
    {
        if (m_ScoreDataArrayIndex == m_ScoreDataArray.Length)
        {
            return(true);
        }
        m_Counter = 0;

        CScoreData ScoreData = m_ScoreDataArray[m_ScoreDataArrayIndex];

        m_ScoreDataArrayIndex++;

        m_ScoreIncrementer_Text.color        = new Color(m_ScoreIncrementer_Text.color.r, m_ScoreIncrementer_Text.color.g, m_ScoreIncrementer_Text.color.b, 1.0f);
        m_ScoreIncrementerContent_Text.color = new Color(m_ScoreIncrementerContent_Text.color.r, m_ScoreIncrementerContent_Text.color.g, m_ScoreIncrementerContent_Text.color.b, 1.0f);
        m_ScoreIncrementer_Text.text         = "0";
        m_ScoreIncrementerContent_Text.text  = ScoreData.Content;
        m_CounterTarget = ScoreData.CounterTarget;

        return(false);
    }
コード例 #2
0
ファイル: CGameGUI.cs プロジェクト: chuwilliamson/Group3
 void Awake()
 {
     scoreKeeper = GameObject.FindGameObjectWithTag("ScoreKeeper").GetComponent <CScoreData>();
 }