Use this code (cocos2dx v3.x):
node->runAction( Sequence::create( Spawn::create(A, B, nullptr),
C,
nullptr));
This is what happen:
- A and B start simultaneously
- After the longer one finished, C start.
Important: Remember that you should use finite action when using Sequence
. for example you should not use RepeatForever
for actions when use them in Sequence
.
cocos2d v2.x
node->runAction( CCSequence::create( CCSpawn::create(A, B, NULL),
C,
NULL));