hello,
I have a banner that I want to both rotate and scale and have it repeat forever. I want to have the rotation action at a different period than the scale action so the banner doesn't look like it is following the same path over and over again.
I can get it to work if both the scale and rotation action durations are the same and if they are not then the one action will stop and wait for the other to complete before repeating.
I have also tried adding the CCRepeatForever to the CCSpawn actions which does not work.
Any ideas of how to do this would be appreciated.
Regards,
id rotAction = [CCRotateBy actionWithDuration:2.0 angle:40];
id rotEaseAction = [CCEaseSineInOut actionWithAction:rotAction];
id rotSequence = [CCSequence actions: [[rotEaseAction copy] autorelease],[rotEaseAction reverse], nil];
id scaleToAction = [CCScaleTo actionWithDuration: 2.0 scale: 2.0f];
id scaleFromAction = [CCScaleTo actionWithDuration: 2.0 scale: 1.0f];
id scaleSequence = [CCSequence actions: scaleToAction, scaleFromAction, nil];
id actionAll = [CCSpawn actions: rotSequence, scaleSequence, nil];
id actionRepeat = [CCRepeatForever actionWithAction:actionAll];
[banner runAction:actionRepeat];