Exemplo n.º 1
0
 public NewbieStepBase FindCertainStep(ENewbieStepType inStepType)
 {
     for (int i = 0; i < this._allSteps.Count; i++)
     {
         NewbieStepBase newbieStepBase = this._allSteps[i];
         if (newbieStepBase.IsStep(inStepType))
         {
             return(newbieStepBase);
         }
     }
     return(null);
 }
Exemplo n.º 2
0
        public void MoveNextStep()
        {
            if (this._curStep == null)
            {
                return;
            }
            NewbieStepBase nextStep = this._curStep.GetNextStep();

            if (nextStep == null)
            {
                return;
            }
            this._curStep.OnLeave();
            nextStep.HandleAction();
            this._curStep = nextStep;
            this._curStep.DescribeSelf();
        }
Exemplo n.º 3
0
        public bool MoveCertainStep(ENewbieStepType inStepType, bool inIsCheckCurStep, ENewbieStepType inCheckStepType)
        {
            if (inIsCheckCurStep && this._curStep.GetStepType() != inCheckStepType)
            {
                return(false);
            }
            NewbieStepBase newbieStepBase = this.FindCertainStep(inStepType);

            if (newbieStepBase == null)
            {
                return(false);
            }
            if (this._curStep.GetStepType() == newbieStepBase.GetStepType())
            {
                return(false);
            }
            this._curStep.OnLeave();
            newbieStepBase.HandleAction();
            this._curStep = newbieStepBase;
            this._curStep.DescribeSelf();
            return(true);
        }
Exemplo n.º 4
0
 public void BindNextStep(NewbieStepBase inStep)
 {
     this._nextStep = inStep;
 }