Пример #1
0
 // Use this for initialization
 void Start()
 {
     amyModel      = HumanoidStore.GetAmyModel();
     chanionModel  = HumanoidStore.GetChanionModel();
     enemiesModels = HumanoidStore.GetEnemiesModels();
     enemyMarkers  = EnemyMarkerStore.GetEnemyMarkers();
 }
Пример #2
0
 void Start()
 {
     humanoidSubscribers.Add(HumanoidStore.GetAmyModel());
     humanoidSubscribers.Add(HumanoidStore.GetChanionModel());
     foreach (AIHumanoidModel enemy in HumanoidStore.GetEnemiesModels())
     {
         humanoidSubscribers.Add(enemy);
     }
 }
Пример #3
0
    public bool KeepDestination(MapNode node)
    {
        List <AIHumanoidModel> allies = HumanoidStore.GetEnemiesModels();
        bool    free           = true;
        Vector3 nodeLocation   = node.GetLocation();
        Vector2 nodeLocation2D = nodeLocation.To2D();

        foreach (AIHumanoidModel ally in allies)
        {
            if (Vector3.Distance(ally.InfoGetCenterBottom(), nodeLocation)
                < occupancyRadius)
            {
                free = false;
                break;
            }
        }

        return(free && node.IsCoverNode() && attackPlanner.TooCloseToEnemyBounds(
                   enemyAvoidanceRadius
                   ));
    }