示例#1
0
 void Start()
 {
     _barsUpdater = GetComponentInChildren <BuildingBarsUpdaterScript>();
     if (smokeVFX)
     {
         smokeVFX.Stop();
     }
 }
示例#2
0
    // Start is called before the first frame update
    void Start()
    {
        _unitType               = UnitType.vehicle;
        _barsUpdater            = GetComponentInChildren <BuildingBarsUpdaterScript>();
        _barsUpdater._maxHealth = Health;

        _navAgent        = GetComponent <NavMeshAgent>();
        _worldController = WorldController.GetWorldController;
        _worldController._workers.Add(this);
        _localTaskList  = new List <UnitTask>();
        _navAgent.speed = _speed;
        Energy          = 100;
        _taskLibary     = TaskLibrary.Get();
        //SetTool();
    }