pygame is

pygame.org is
Rock Blaster

# Rock Blaster - 0.10

### Description

This is my first attempt with writing a Pygame game. It's pretty simple at this point. Blast away to earn points until you die. I plan to add an ending and more interesting enemies later. I'm new to this and constructive feedback is appreciated. Thanks! Note - The poor artwork is mine, but I used a Nasa (public domain) image for the background.

### Screenshot

click to view original size

### Releases

 Rock Blaster - 1.0 - Sep 24, 2008 Rock Blaster - 0.10 - Aug 24, 2008

September 29, 2008 1:52am - Jeff W - nickname: (jwalt)
Nevermind, answered my own question. You mean add a buffer space on each side of the screen. I guess I'm a little slow. =)
September 28, 2008 11:25pm - Jeff W - nickname: (jwalt)
Thanks. Yeah, I don't really like how that happens, but it was the first way to do it that I could think of. Your way makes a lot of sense. (Actually it makes a lot of sense for moving anything.) I have a dumb question though - can you define 'tab'?
September 28, 2008 4:03pm - Andy Hanson - nickname: (rhodiumgames)
Edit: Line 4 is
Choose a random angle going from 0 to 90 degrees either way from down
September 28, 2008 4:02pm - Andy Hanson - nickname: (rhodiumgames)
I'm guessing your rock-creation algorithm goes like this:
Choose x in range [0,screenWidth]
It's at the top
Choose a random angle going 90 degrees either way from down
This means that some rocks are going to start at the edge and move off the edge horizontally. UNFAIR!
Better algorithm:
Choose x in range [tab,screenWidth - tab]
It's at the top
Choose ending x in range [tab,screenWidth - tab]
Ending y is screenHeight of course
Calculate angle so that you'll reach (ending x,ending y)
Tab doesn't have to be too big, but the ship stops when its wing reaches the edge, so if a rock was partly offscreen then you might not be able to shoot it.
spotlight

our projects
pygame.org welcomes all python game, art, music, sound, video and multimedia projects. If they use pygame or not.

recent releases
May 24, 2013

May 23, 2013

May 22, 2013

May 21, 2013

May 19, 2013

May 18, 2013

May 17, 2013

May 16, 2013

May 15, 2013

... more!

for pygame related questions, comments, and suggestions, please see help (lists, irc)