1
我是cocos2的絕對初學者,實際上我昨天開始處理它。我想要做的是沿着貝塞爾曲線移動圖像。這是我該怎麼做如何在cocos 2d中實現均勻的運動速度?
- (void)startFly
{
[self runAction:[CCSequence actions:
[CCBezierBy actionWithDuration:timeFlying bezier:[self getPathWithDirection:currentDirection]],
[CCCallFuncN actionWithTarget:self selector:@selector(endFly)],
nil]];
}
我的問題是,圖像移動不均勻。一開始它的運動速度很慢,然後逐漸加速,最後運動的速度非常快。我應該怎麼做才能擺脫這種加速度?