open source pong or equally simple game

D

Dr_Locke_Z2A

I was talking to my uncle the other day about getting into programming
games and he recommended to start teaching myself with really simple
games, like Pong simple. So I looked on google and gnu.org and a few
other places and can't seem to find an open source pong clone. I did
find something called 3D Pong, but I'm thinking that would be a bit
more complicated. Can anyone point me in the right direction for
finding such an open source game in C?
 
M

Michael Mair

Dr_Locke_Z2A said:
I was talking to my uncle the other day about getting into programming
games and he recommended to start teaching myself with really simple
games, like Pong simple. So I looked on google and gnu.org and a few
other places and can't seem to find an open source pong clone. I did
find something called 3D Pong, but I'm thinking that would be a bit
more complicated. Can anyone point me in the right direction for
finding such an open source game in C?

1) You cannot write Pong in portable standard C.
2) So, you may ask again in a newsgroup for your implementation.
3) googling for "pong C source" was halfway successful from my point
of view -- how were you able to miss the article series? (No, it is
not good C but it may be what _you_ need.)

Cheers
Michael
 
J

Joe Estock

Michael said:
Dr_Locke_Z2A wrote:
[snip]


1) You cannot write Pong in portable standard C.

Not entirely true. Using printf and the escape sequence for the
backspace key you could implement a fairly workable version that is very
close to standard C, however I don't think it would be very playable. It
might be a good starting point at learning the algorithms involved, however.
2) So, you may ask again in a newsgroup for your implementation.
3) googling for "pong C source" was halfway successful from my point
of view -- how were you able to miss the article series? (No, it is
not good C but it may be what _you_ need.)

Cheers
Michael

There are several resources dedicated to game development, each ranging
from platform specific to platform independant. Check on Amazon.com as
well as your local bookstore (Borders has quite a selection on this topic).

Joe
 
K

Kenneth Brody

Joe said:
Michael said:
Dr_Locke_Z2A wrote:
[snip]


1) You cannot write Pong in portable standard C.

Not entirely true. Using printf and the escape sequence for the
backspace key you could implement a fairly workable version that is very
close to standard C, however I don't think it would be very playable. It
might be a good starting point at learning the algorithms involved, however.

Well, given that backspacing will limit you to a single line of display
(assuming that you have a "display" which can backspace), it will be even
more boring as you can't take any input from the user without pausing
every time and waiting for Enter to be pressed (which will make the
backspace issue moot as the cursor will probably advance to the next line
at that point).

[...]

--
+-------------------------+--------------------+-----------------------------+
| Kenneth J. Brody | www.hvcomputer.com | |
| kenbrody/at\spamcop.net | www.fptech.com | #include <std_disclaimer.h> |
+-------------------------+--------------------+-----------------------------+
Don't e-mail me at: <mailto:[email protected]>
 
C

Chuck F.

Kenneth said:
Joe said:
Michael said:
[snip]

1) You cannot write Pong in portable standard C.

Not entirely true. Using printf and the escape sequence for
the backspace key you could implement a fairly workable
version that is very close to standard C, however I don't
think it would be very playable. It might be a good starting
point at learning the algorithms involved, however.

Well, given that backspacing will limit you to a single line of
display (assuming that you have a "display" which can
backspace), it will be even more boring as you can't take any
input from the user without pausing every time and waiting for
Enter to be pressed (which will make the backspace issue moot as
the cursor will probably advance to the next line at that
point).

And who says that there is a terminal device capable of back
spacing? Teletypes couldn't. I also had to handle some CRT
terminals that couldn't. Who says that any output device is
connected? None of these things are specified by the standard.

--
"If you want to post a followup via groups.google.com, don't use
the broken "Reply" link at the bottom of the article. Click on
"show options" at the top of the article, then click on the
"Reply" at the bottom of the article headers." - Keith Thompson
More details at: <http://cfaj.freeshell.org/google/>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,734
Messages
2,569,441
Members
44,832
Latest member
GlennSmall

Latest Threads

Top