// Use this for initialization
 void Awake()
 {
     if (HealthBar == null)
     {
         HealthBar = GetComponent <statusBar>();
     }
 }
示例#2
0
 private void Awake()
 {
     if (bar == null)
     {
         bar        = GetComponent <statusBar>();
         bar.status = 1;
     }
 }