Bouncing Ball (Dev C++ GUI code)

Please support our C++ advertiser: Intel Parallel Studio Home
0
vegaseat vegaseat is offline Offline | Jan 25th, 2005
I simplified the code somewhat by removing the run one instance only feature.
 
0
Young Teck 06 Young Teck 06 is offline Offline | Jan 29th, 2005
works fine for me :-)
 
0
xgills xgills is offline Offline | Apr 27th, 2006
is there a way we can change the speed?
 
0
vegaseat vegaseat is offline Offline | Oct 2nd, 2006
You can change the speed in this commented line:
// 50ms here, lower value gives higher speed
SetTimer((HWND)Form1,1,50,NULL);
 
0
Lazaro Claiborn Lazaro Claiborn is offline Offline | Mar 1st, 2007
There is a problem, I just haven't found it yet. :lol: Just kidding. Looks great and works fine. Kudo's.
 
0
lucamarcus lucamarcus is offline Offline | Oct 20th, 2007
Am a new c++ programmer.

I refer to the code " Bouncing Ball" which is a GUI, now there is a rectangle created, i managed to change the color the rectangle in the main window and what my may problem is how to make the rectangle fixed and not only increase to be a full rectangle after the ball has hit both ends, how do i achieve that?

Secondly, i would love to then after making a 'fixed' rectangle, i would like to make the ball change color as it hits one side of the rectangle and change back to the original color as its starts coming back and approaches the other side and again change color as it hits the other side and change back again as it approaches the other side and keep repeating this cycle...

I need the rectangle to be fully drawn or fixed EVEN before the ball starts moving and then the change of colors issue.

PLEASE ASSITS
 
 

Message:


Thread Tools Search this Thread



Tag cloud for C++
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC