Exemplo n.º 1
0
 void Ready()
 {
     for (int i = 0; i < pooledObjects.Count; i++)
     {
         Misile m = (Misile)pooledObjects[i];
         m.GetInPosition(setupPositions[i] + transform.position);
         m.Aim(GameController.GC.Player.position);
     }
 }
Exemplo n.º 2
0
    void Aim()
    {
        int arriveCount = 0;

        for (int i = 0; i < pooledObjects.Count; i++)
        {
            Misile m = (Misile)pooledObjects[i];

            m.GetInPosition(setupPositions[i] + transform.position);
            if (m.InPosition)
            {
                arriveCount++;
                m.Aim(GameController.GC.Player.position);
            }
        }
        if (arriveCount >= pooledObjects.Count)
        {
            StartCoroutine(ReadyTimer());
        }
    }