Quantcast
Channel: cocos2d-x - Cocos Forums
Viewing all articles
Browse latest Browse all 2748

Panning animation for a special background

$
0
0

@digimikeh wrote:

Hi!..

I have my background, is a long stripe, a 4096 (h) x 768 (w) .jpg file, what i´m looking is to animate panning from begin to finish and then repeat it, say:

  1. Move the bg from x450 to -x450
  2. wait untill finished
  3. set bg position to x450
  4. repeat the process

I got 1), but can´t imagine how to wait, i was thinking on scheduleOnce, but that will pause only once, so i think i can use a for/while kind loop or recursive… is there any other builtin alternative?

Thanks in advance…

Posts: 3

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 2748

Trending Articles