I present to you, the laurels of about... maybe an hour of work... PONG!

This version of PONG is for the Casio Prizm, very true to the original, and meeting the goals of development I planned for it:

- under 50KB total for the entire Add-in
- achieves over 15 FPS with decent video effects
- entirely developed in under an hour
- uses only routines available in the Useful Prizm Routines and libfxcg

I did this as a proof that native development on the Prizm is very easy to do now, even without an abstraction layer like SDL. It also is meant for beginning C for the Prizm programmers to tear apart as a very easy game example, from which they can learn to make their own Add-ins.

That being said, I also took my spare time to add in some small video noise effects to make it look cooler, and both an AI and 2 Player mode. Controls are:

F1/F2 - menu choices
Shift/Alpha - Player 1 Up/down
Up/Down - Player 2 up/down
Exit - exit to title screen

Tear it apart and enjoy it! It's far from perfect, but it's still fun to play. If you do try to learn by improving upon it, and re-releasing it, give me some credit, s'il vous plait. Full source and build system obviously included.

EDIT: Don't try it in the emulator. It won't work past the main menu. This is due to me using my hacky getkey routines that the emulator can't detect. Try it on hardware!

Download:

|::| PONG for Prizm

Heh, I love your download icon on this page, very clever. Can I safely assume that the background is procedurally-generated, and not stored inside the add-in? Is there a reason your PONG is so horribly aliased? That dark red on dark green is a bit hard to read. I don't suppose you have any screenshots, presumably camera-recorded, of ingame play?
KermMartian wrote:
Heh, I love your download icon on this page, very clever. Can I safely assume that the background is procedurally-generated, and not stored inside the add-in? Is there a reason your PONG is so horribly aliased? That dark red on dark green is a bit hard to read. I don't suppose you have any screenshots, presumably camera-recorded, of ingame play?


The background is of course procedurally generated, and while it slows the FPS down some, it's also used for clearing the background. the PONG looks bad because I kind of just rushed through it Razz The red against green actually looks quite fine on hardware, the emulator seems to exaggerate green and under-exaggerate red. And finally, no live screenshots/videos yet, but perhaps I can do that tonight. Smile
Awesome, yet another C game for the Prizm Smile Things have been hot in terms of software releases, fortunately.

The size of the add-in is proof that color games don't need to be giant in size. (about size, think: if we dropped the g3a header, the binary would be only 16,5KB in size!)

I like the retro feel the game has. One of the things that could be interesting to add is a highscore table...

And for next, I'd like Snake coded in C, please Very Happy
gbl08ma wrote:
And for next, I'd like Snake coded in C, please Very Happy


Perhaps I can also use Snake as an example in my WIP C for Prizm tutorial Wink

EDIT: the size could be dropped even smaller, with the icons gone -- probably below 8Kb. The PONG logo is about 6Kb, and I'm on an -Ofast flag, an -Os flag could drop another 1-2KB.

EDIT2: for fun, I took out some stuff to make it bare bones (video effects, logo, copyright image, etc.) and I got it down to 30KB! Smile
Excellent. I've been thinking we really need a good C tutorial for all of the new prizms. It'd be useful for me to learn, too, as most of what I'm currently doing deals with sh3 asm...
graphmastur wrote:
Excellent. I've been thinking we really need a good C tutorial for all of the new prizms. It'd be useful for me to learn, too, as most of what I'm currently doing deals with sh3 asm...
Well, in the end it's really just C with a few extra things to understand with graphics, since we have no stdlib. Still, it would be great to have a C tutorial that walks the user through C basics by way of the Prizm, to be sure.
KermMartian wrote:
graphmastur wrote:
Excellent. I've been thinking we really need a good C tutorial for all of the new prizms. It'd be useful for me to learn, too, as most of what I'm currently doing deals with sh3 asm...
Well, in the end it's really just C with a few extra things to understand with graphics, since we have no stdlib. Still, it would be great to have a C tutorial that walks the user through C basics by way of the Prizm, to be sure.

See, and I've noticed a lot of our users don't know a thing about how strings work or anything like that, so a small tutorial with that would be nice too. I was thinking we could either make it a small C and mostly Prizm C tutorial, or just make it all Prizm and assume they know enough C or can figure it out based on code.
Update: since this is an example program, I decided to comment it up to the brink. It's super insightful now, and should help any intermediate to advanced C programmer start programming for the prizm ASAP: http://www.cemetech.net/programs/index.php?mode=file&id=701
Graphmastur: I think that's a reasonable sort of tutorial to write, perhaps Ashbad could incorporate something along those lines into his guide, and/or you could write something like that, provided you have the time? Also, Ashbad, good updates, and that's some extremely thorough (bordering on excessive Wink ) commenting.
KermMartian wrote:
Graphmastur: I think that's a reasonable sort of tutorial to write, perhaps Ashbad could incorporate something along those lines into his guide, and/or you could write something like that, provided you have the time? Also, Ashbad, good updates, and that's some extremely thorough (bordering on excessive Wink ) commenting.

I wouldn't mind in a few weeks when I have time. I'll probably end up doing a bunch of prizm hacking this summer. I can tell you now it won't be this week.

Thanks for the update Ashbad!
My sister is still trying to find out whether she likes pong or tetrizm better. Great Job, ashbad! Smile
flyingfisch wrote:
My sister is still trying to find out whether she likes pong or tetrizm better. Great Job, ashbad! Smile


Thanks, but I must admit that both flatters and depresses me -- Tetrizm took Kerm many man hours to make, and is at a much higher quality than PONG, which took me 60 minutes to make. I guess all's fair in love and calculator gaming, though Wink I actually have to say I'm surprised that people actually like this game, since while it's a full-on PONG game, it's primary purpose was actually as a learning example.
Ashbad wrote:
flyingfisch wrote:
My sister is still trying to find out whether she likes pong or tetrizm better. Great Job, ashbad! Smile


Thanks, but I must admit that both flatters and depresses me -- Tetrizm took Kerm many man hours to make, and is at a much higher quality than PONG, which took me 60 minutes to make. I guess all's fair in love and calculator gaming, though Wink I actually have to say I'm surprised that people actually like this game, since while it's a full-on PONG game, it's primary purpose was actually as a learning example.

Time and quality aren't the only thing good about a game (nothing against tetrizm, i love it). Pong is very addictive, which is why she likes it Wink
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement