Пример #1
0
 public virtual void Update()
 {
     if (shields < maxShields && shieldCooldown.Interval(shieldRepairCooldown).Ready())
     {
         shields += shieldRepairRate * Time.deltaTime;
         if (shields > maxShields)
         {
             shields = maxShields;
         }
         if (ship.statusBar && ship.statusBar.isActiveAndEnabled)
         {
             ship.statusBar.SetShields(shields, maxShields);
         }
     }
 }