0

我是 cocos2D 的新手

我想在屏幕上拖动时绘制类似于附图中的粒子的云状粒子。我尝试使用 CCParticleSmoke,但无法控制粒子的扩散。初始化:

  smoke = [[CCParticleSmoke alloc] initWithTotalParticles:100];
  smoke.texture = [[CCTextureCache sharedTextureCache] addImage:@"cloud.png"];
  smoke.gravity = CGPointZero;
        smoke.startColor = _color;
  smoke.posVar = CGPointZero;

在手势方法中

 smoke.position = pointPosition;
  [smoke visit];

当我运行我的代码时,虽然我平行拖动,但会出现垂直云状粒子。无法获得有关该做什么的任何线索。我不希望粒子扩散,但如下图所示。任何及时的帮助表示赞赏。

谢谢。

想要像

4

0 回答 0