-
The main goal with this project is demonstrate the power of python programing language, and how simple it is to implement a basic application concept.
-
Nasa vs Aliens is a game developed to bring back the nostalgia of the 80s and 90s 2d games. This application target is mostly people that enjoy a good, light old fashioned game to pass the time or simply for the act of socializing.
Visible through out each match, shows players the status of their ship. Each player has 10 life points, whenever a player reaches 0 the game is restarted.
Players can share the same keyboard in order to play a match.
- The left player uses the following keys:
- UP --> W
- DOWN --> S
- LEFT --> A
- RIGHT --> D
- SHOOT --> SPACE-BAR
- The right player uses the following keys:
- UP --> ARROW UP
- DOWN --> ARROW DOWN
- LEFT --> ARROW LEFT
- RIGHT --> ARROW RIGHT
- SHOOT --> RIGHT CTRL
To make the game more exciting, players can only fire 5 bullets at the time. Players are not allowed to fire again until their bullets are either off the screen or have hit the enemy ship.
Each time the opposite side reaches 0 health the winner is announced.
- In a near future I would like to implement a intro that presents the game.
- Add a menu that let players choose their game character.
The code for this program was tested using the following:
The PEP8 - validator validator have shown some warnings with the code written, these warnings don't create any problems and were therefore ignored:
PEP8 - Result File containing the results and the code.
I have commented out the code regarding the sound effects on lines 42, 43, 202, 210, 214, 217 on the run.py file on replit. The main reason being replit does not execute the pygame sound library.
When the application executed the following error appears in my command line:
libpng warning: iCCP: known incorrect sRGB profile
When the application is stopped the following error appears in my command line:
pygame.error: video system not initialized
None of the above stops the program from running and executing, which makes me believe that is a problem with some of the pygame libraries.
- The project was developed using Pygame.
Pygame is a set of Python modules designed for writing video games. Pygame adds functionality on top of the excellent SDL library. This allows you to create fully featured games and multimedia programs in the python language.
Pygame is free. Released under the LGPL licence, you can create open source, freeware, shareware, and commercial games with it. See the licence for full details.
-
Sound effects obtained from Zapsplat.
-
The photos used on the home and sign up page are from Pexels.
-
The spaceship images were obtained from NicePNG.
-
A big thanks to Alan and the Student Support team for coming up with the deployment idea and of course for their time.
-
Thanks to Spencer my mentor for being so prompt and active when questions arise.