Beispiel #1
0
 void Awake()
 {
     _isPlayer      = (GetComponent <Character> () != null) ? true : false;
     _currentHealth = _maximumHealth;
     _inventory     = GetComponent <Inventory>();
     _renderer      = GetComponent <Renderer>();
     _baseMaterial  = _renderer.material;
     if (_vitalPoints.Length > 0)
     {
         _vitals.SetVitals(_vitalPoints);
     }
     else
     {
         _vitals.SetVitals(transform);
     }
 }