365
365
< ul class ="md-nav__list " data-md-scrollfix >
366
366
367
367
< li class ="md-nav__item ">
368
- < a href ="#sequencenode " title ="SequenceNode " class ="md-nav__link ">
369
- SequenceNode
368
+ < a href ="#sequencenode-default " title ="SequenceNode (default) " class ="md-nav__link ">
369
+ SequenceNode (default)
370
370
</ a >
371
371
372
372
</ li >
518
518
< ul class ="md-nav__list " data-md-scrollfix >
519
519
520
520
< li class ="md-nav__item ">
521
- < a href ="#sequencenode " title ="SequenceNode " class ="md-nav__link ">
522
- SequenceNode
521
+ < a href ="#sequencenode-default " title ="SequenceNode (default) " class ="md-nav__link ">
522
+ SequenceNode (default)
523
523
</ a >
524
524
525
525
</ li >
559
559
560
560
< h1 id ="sequences "> Sequences</ h1 >
561
561
< p > A < strong > Sequence</ strong > ticks all it's children, from left to right, as long as
562
- they return SUCCESS. If any child returns FAILURE, the sequence is suspended .</ p >
563
- < p > Here we introduce different kinds of TreeNodes :</ p >
562
+ they return SUCCESS. If any child returns FAILURE, the sequence is aborted .</ p >
563
+ < p > Here we introduce different kinds of sequence nodes :</ p >
564
564
< ul >
565
565
< li > SequenceNode</ li >
566
566
< li > SequenceStarNode</ li >
@@ -577,7 +577,7 @@ <h1 id="sequences">Sequences</h1>
577
577
578
578
579
579
< p > Use < strong > SequenceStarNode</ strong > if, instead, the answer is: </ p >
580
- < div class ="codehilite "> < pre > < span > </ span > A: "Try again to execute the failed child.
580
+ < div class ="codehilite "> < pre > < span > </ span > A: "Try again to execute the child that failed .
581
581
Do not re-tick children which succeeded already."
582
582
</ pre > </ div >
583
583
@@ -586,15 +586,15 @@ <h1 id="sequences">Sequences</h1>
586
586
once. If any of them failed, the SequenceAllNode returns FAILURE. </ p >
587
587
< p > The shared logic is:</ p >
588
588
< ul >
589
- < li > Before ticking the first child, SequenceNode becomes < strong > RUNNING</ strong > .</ li >
589
+ < li > Before ticking the first child, sequence becomes < strong > RUNNING</ strong > .</ li >
590
590
< li > If a child returns < strong > SUCCESS</ strong > , it ticks the next child.</ li >
591
591
< li > If the < strong > last</ strong > child returns < strong > SUCCESS</ strong > too, all the children are halted and
592
- the SequenceNode returns < strong > SUCCESS</ strong > .</ li >
592
+ the sequence returns < strong > SUCCESS</ strong > .</ li >
593
593
< li > If a child returns < strong > RUNNING</ strong > , the sequence suspends and returns < strong > RUNNING</ strong > .
594
594
The next time it is ticked, it will tick the same child again.</ li >
595
595
</ ul >
596
- < p > The three Sequences differ in what they do if a child returns FAILURE.</ p >
597
- < h2 id ="sequencenode "> SequenceNode</ h2 >
596
+ < p > The three sequences differ in what they do if a child returns FAILURE.</ p >
597
+ < h2 id ="sequencenode-default "> SequenceNode (default) </ h2 >
598
598
< p > If a child returns FAILURE, the sequence returns FAILURE.
599
599
Reset the index and halt all the children.
600
600
The entire sequence will be executed again at the next tick.</ p >
0 commit comments