PDA

View Full Version : bouncing ball



north00001
09-29-2000, 03:08 AM
I am trying to get a sphere to bounce randomly in a window, any ideas on how to code this? I am setting up an array vector to hangle this (AVector [3][3]). I ultimately will bounce three balls that is the reason for the two dimentional array. If this is confusing and there is a better way please inform me.
Thanks

[This message has been edited by north00001 (edited 09-29-2000).]

Dodger
09-29-2000, 10:38 AM
How is the sphere supposed to be bouncing? Like a rubber ball that is pulled down by gravity, like a flipper ball bouncing off the edges of your window?

BasKuenen
09-29-2000, 11:15 AM
Hi north00001,

I've just made a new tutorial on physics on my site. It's for OpenGL with complete source & demo. http://www.baskuenen.myweb.nl/gravity.htm

[This message has been edited by BasKuenen (edited 09-29-2000).]

north00001
09-29-2000, 06:53 PM
I wanted to have the sphere move randomly in the window and reflect back in at the edges. I didn't realize it was this involved. With that said, I guess we could use the earths gravity. Actually the sphere is an atomic element like hydrogen which I was trying to model moving freely in the window. Thanks in advance for any input.


Originally posted by Dodger:
How is the sphere supposed to be bouncing? Like a rubber ball that is pulled down by gravity, like a flipper ball bouncing off the edges of your window?