Asteroids game using Python - Pygame module

Asteroids is a video arcade game released in November 1979 by Atari Inc. It was one of the most popular and influential games of the Golden Age of Arcade Games, selling 70,000 arcade cabinets. Asteroids uses a vector display and a two-dimensional view that wraps around in both screen axes. The player controls a spaceship in an asteroid field which is periodically traversed by flying saucers. The object of the game is to shoot and destroy asteroids and saucers while not colliding with either, or being hit by the saucers' counter-fire.

This game is similar to asteroids with some features...

Github - Asteroids Pygame source files

(After extracting the zip file open dist folder and click on "Enterprise.exe" file to run)
( Had problems while converting Python to exe so this demo has no sounds or scores and lives displayed :P )

Splash screen

Gameplay - 1

Gameplay - 2


  1. When you try to run the program, i has an error staring that xrange is not defined. Could you give me a fix for this?

    1. Hello.. This code was written long ago with python 2.x compiler.

      I guess you're using python 3.x, where xrange is not used anymore. So to fix it, change all xrange to range.

      Thanks for notifying. I'll modify the codebase as well when I get time..

  2. Can you write this game with c++?


Post a Comment

Popular posts from this blog

Creating jokes by violating Grice’s maxims

Euphemisms and Political correctness - the lies we use to shun reality