Beispiel #1
0
    //// Private methods
    void UnpackEnemyAttributes(EnemyAttributes attributes)
    {
        _totalLife = _currentLife = attributes.life;
        _lifeBar.SetUp(_totalLife);

        _aiAgent.speed = attributes.speed;
    }
Beispiel #2
0
    void Start()
    {
        _gameManager = GameManager.Instance;

        _spawnSystem = _gameManager.Enemies;

        _coreTotalLife        = _gameManager.CoreTotalLife;
        _currentLife          = _coreTotalLife;
        _secondsToCheckMenace = _gameManager.CoreMenaceCheckPeriod;
        _lifeBar.SetUp(_coreTotalLife);
    }