예제 #1
0
        public void Generate(int startCoroutineId)
        {
            this.RootCoroutineId = startCoroutineId;
            this.State           = RuntimeState.TestGen;
            _stepEntityRoot      = ModuleUtils.CreateStepModelChain(_sequence.Steps, _context, _sequence.Index);
            if (null == _stepEntityRoot)
            {
                return;
            }

            StepTaskEntityBase stepEntity = _stepEntityRoot;

            do
            {
                stepEntity.Generate(ref startCoroutineId);
            } while (null != (stepEntity = stepEntity.NextStep));

            this.State = RuntimeState.StartIdle;
            // 添加当前根节点到stepModel管理中
            StepTaskEntityBase.AddSequenceEntrance(_stepEntityRoot);
        }