File tree Expand file tree Collapse file tree 3 files changed +5
-2
lines changed Expand file tree Collapse file tree 3 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -387,9 +387,9 @@ - (void)runActionsForNode:(CCNode*)node sequenceProperty:(CCBSequenceProperty*)s
387387 CCActionSequence* seq = [CCActionSequence actionWithArray: actions];
388388 seq.tag = _animationManagerId;
389389 [seq startWithTarget: node];
390- if (startFrame == 0 && _loop) { // Ensure Sync
390+ if (kf0. time > 0 || _loop) { // Ensure Sync
391391 [seq step: 0 ];
392- [seq step: _runningSequence.time-kf0.time];
392+ [seq step: _runningSequence.time-kf0.time - _runningSequence.tween ];
393393 }
394394 [_currentActions addObject: seq];
395395}
@@ -464,6 +464,7 @@ - (void)runAnimationsForSequenceId:(int)seqId tweenDuration:(float) tweenDuratio
464464 // Set the running scene
465465 _runningSequence = [self sequenceFromSequenceId: seqId];
466466 _runningSequence.time = 0 .0f ;
467+ _runningSequence.tween = tweenDuration;
467468
468469 [self addSequenceCallBacks: seqId tweenDuration: tweenDuration startTime: 0 ];
469470
Original file line number Diff line number Diff line change 3535@property (nonatomic ,assign ) int sequenceId;
3636@property (nonatomic ,assign ) int chainedSequenceId;
3737@property (nonatomic ,assign ) int loops; // @todo
38+ @property (nonatomic ,assign ) float tween;
3839
3940// Channels
4041@property (nonatomic ,strong ) CCBSequenceProperty* callbackChannel;
Original file line number Diff line number Diff line change @@ -42,6 +42,7 @@ - (id)init
4242
4343 _callbackChannel = nil ;
4444 _soundChannel = nil ;
45+ _tween = 0 .0f ;
4546
4647 return self;
4748}
You can’t perform that action at this time.
0 commit comments