very simple trouble that makes me crazy

hi to all of you.

Just a simple question:

I need 30 images of a simple ball that move randomly arround the screen, and when they touch a border of screen, changes their direction.

i can’t do it grrr!!

 i have set the borders , with out gravity , load the images, but y can not do the movement. 

please…help!.

Regards.

Use transition.to in order to move the balls around. Use onComplete listeners to keep the balls moving, i.e. when a ball has reached its destination (a screen border), do a new transition.

Transition.to and onComplete listeneres are documented here: http://docs.coronalabs.com/api/library/transition/to.html

It’s not a good idea to mix physics and transitions. If you do it with physics, apply impulses to the objects. Check it out here: http://docs.coronalabs.com/api/type/Body/applyLinearImpulse.html

http://docs.coronalabs.com/api/type/Body/setLinearVelocity.html

would also work

Use transition.to in order to move the balls around. Use onComplete listeners to keep the balls moving, i.e. when a ball has reached its destination (a screen border), do a new transition.

Transition.to and onComplete listeneres are documented here: http://docs.coronalabs.com/api/library/transition/to.html

It’s not a good idea to mix physics and transitions. If you do it with physics, apply impulses to the objects. Check it out here: http://docs.coronalabs.com/api/type/Body/applyLinearImpulse.html

http://docs.coronalabs.com/api/type/Body/setLinearVelocity.html

would also work