The Daily Click ::. Forums ::. Misc Chat ::. First C++ Game
 

Post Reply  Post Oekaki 
 

Posted By Message

hop



Registered
  16/03/2005
Points
  916
27th August, 2005 at 15:32:02 -

Hello!

I made my first game using C++. It's Pong!
I'm not posting this under downloads cause it's extremly simple and was wondering what the community's reaction would be to C++ games by members, hopefully not a similar reaction to the dreaded GameMaker.
Controls:
w = move paddle up
s = move paddle down
q = quit
any other key = stop paddle from moving
http://www.sitesled.com/members/fusiongames/Pong.exe

Image Edited by the Author.

 
Working On:
Psydude
Castle Wars(working title)

XBLGT: sunstrike9

Radix

hot for teacher

Registered
  01/10/2003
Points
  3139

Has Donated, Thank You!VIP MemberGOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!GOTW WINNER CUP 4!
27th August, 2005 at 15:36:30 -

Wow, just like pong only barely playable. What made you think it would be a good idea to have the paddle keep moving on its own?

 
n/a

hop



Registered
  16/03/2005
Points
  916
27th August, 2005 at 16:21:07 -

Because this was the alternitive:
http://www.sitesled.com/members/fusiongames/Pong2.exe

You have to hit the key every time for it to move, or hold it and wait for the key-repeat to start, like typing. And even while holding it down it's not as fast.

I'm sure there's a way to aviod this, I just haven't found the right function yet.

 
Working On:
Psydude
Castle Wars(working title)

XBLGT: sunstrike9

Justin



Registered
  03/02/2003
Points
  52
27th August, 2005 at 17:06:11 -

start moving on WM_KEYDOWN stop moving on WM_KEYUP ? or am i missing something.

 
n/a

hop



Registered
  16/03/2005
Points
  916
27th August, 2005 at 17:18:42 -

I'm brand new to C++ so I haven't used those before. I'll search for an example and try to implement it.

 
Working On:
Psydude
Castle Wars(working title)

XBLGT: sunstrike9

Dogzer



Registered
  07/02/2011
Points
  1029
27th August, 2005 at 21:23:58 -

show me the source code! =D

 
n/a

tdc052621



Registered
  20/12/2002
Points
  908
27th August, 2005 at 22:34:40 -

LOL, Im new to C++ and i believe the engine for pong is fairly easy to make.

 
n/a

Dogzer



Registered
  07/02/2011
Points
  1029
27th August, 2005 at 23:16:51 -

what graphic library did you use?

 
n/a

hop



Registered
  16/03/2005
Points
  916
28th August, 2005 at 10:04:26 -

I know, the engine was extremely easy to make, it only took about 45 mins, but this IS the first game I've ever made and I simply don't know how to use WM_KEYDOWN and other stuff.

I used the Borland Graphics Lib and compiled with Dev C++. Here's the source in a text file:
http://www.sitesled.com/members/fusiongames/Pong.txt

EDIT: That's the second version of the program btw (the one I don't like as much). The only difference is there's no ELSE to go with the if that tests KBHIT.

Image Edited by the Author.

 
Working On:
Psydude
Castle Wars(working title)

XBLGT: sunstrike9
   

Post Reply



 



Advertisement

Worth A Click