Esempio n. 1
0
 /// <summary>
 /// Updates the lives
 /// </summary>
 /// <param name="lives">Lives left</param>
 void UpdateLivesUI(float lives)
 {
     m_Lives.DOFillAmount(lives / 10, 0.3f);
     if (lives > 7)
     {
         Effects.ChangeImageColor(m_Lives, Effects.s_EffectColors["Green"], 0.3f);
     }
     else if (lives <= 7 && lives > 3)
     {
         Effects.ChangeImageColor(m_Lives, Effects.s_EffectColors["Yellow"], 0.3f);
     }
     else if (lives <= 3)
     {
         Effects.ChangeImageColor(m_Lives, Effects.s_EffectColors["Red"], 0.3f);
     }
 }