Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   C Programming (http://www.velocityreviews.com/forums/f42-c-programming.html)
-   -   open source pong or equally simple game (http://www.velocityreviews.com/forums/t440621-open-source-pong-or-equally-simple-game.html)

Dr_Locke_Z2A 12-22-2005 01:00 AM

open source pong or equally simple game
 
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?


Michael Mair 12-22-2005 01:42 AM

Re: open source pong or equally simple game
 
Dr_Locke_Z2A wrote:
> 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
--
E-Mail: Mine is an /at/ gmx /dot/ de address.

Joe Estock 12-23-2005 06:01 PM

Re: open source pong or equally simple game
 
Michael Mair wrote:
> 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

Kenneth Brody 12-23-2005 07:23 PM

Re: open source pong or equally simple game
 
Joe Estock wrote:
>
> Michael Mair wrote:
> > 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:ThisIsASpamTrap@gmail.com>


Chuck F. 12-23-2005 10:16 PM

Re: open source pong or equally simple game
 
Kenneth Brody wrote:
> Joe Estock wrote:
>> Michael Mair 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).


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/>


All times are GMT. The time now is 05:08 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.