Esempio n. 1
0
 void Update()
 {
     hp = player.getHp();
     if (hp >= nHeart)
     {
         Vector3 theScale = transform.localScale;
         theScale.x           = 1;
         transform.localScale = theScale;
     }
     if (hp < nHeart)
     {
         Vector3 theScale = transform.localScale;
         theScale.x           = 0;
         transform.localScale = theScale;
     }
 }