Пример #1
0
        public void FlyUFO(List <GameObject> waitToFly, Ruler ruler, int round)
        {
            List <SSAction> toMove = new List <SSAction>();

            for (int i = 0; i < waitToFly.Count; i++)
            {
                toMove.Add(CCMoveToAction.GetSSAction(waitToFly[i], ruler.getDes(waitToFly[i].transform.position), ruler.getSpeed(round) * AnimateSpeed, null));
            }
            sequenceAction action = sequenceAction.GetSSAction(1, 0, toMove, this);

            addAction(action);
        }
Пример #2
0
        public void FlyUFO(List <GameObject> waitToFly, Ruler ruler, int round)
        {
            SSAction action;
            float    waitTime = 0;

            for (int i = 0; i < waitToFly.Count; i++)
            {
                Debug.Log("Flying");
                action = CCMoveToAction.GetSSAction(waitToFly[i], ruler.getDes(waitToFly[i].transform.position), ruler.getSpeed(round) * AnimateSpeed, this);
                if (i == 0)
                {
                    addAction(action);
                }
                else
                {
                    addWaitAction(action);
                    StartCoroutine(setNextFly(waitTime, action));
                }
                waitTime += ruler.getIntervals(round);
            }
        }
Пример #3
0
        public void FlyUFO(GameObject gameObject, Ruler ruler, int round)
        {
            CCMoveToAction action = CCMoveToAction.GetSSAction(gameObject, ruler.getDes(gameObject.transform.position), ruler.getSpeed(round) * AnimateSpeed, this);

            addAction(action);
        }