{"id":23325153,"url":"https://github.com/mratanusarkar/space-invaders-pygame","last_synced_at":"2025-09-22T03:30:42.467Z","repository":{"id":128639608,"uuid":"253252173","full_name":"mratanusarkar/Space-Invaders-Pygame","owner":"mratanusarkar","description":"A pygame Implementation of popular Classic Atari and NES Arcade games","archived":false,"fork":false,"pushed_at":"2023-02-27T16:41:11.000Z","size":47145,"stargazers_count":9,"open_issues_count":0,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-01-03T17:51:35.752Z","etag":null,"topics":["arcade-game","atari","classic-game","game","nes","pygame","python","retro","space-invaders","video-arcade-games","video-game"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mratanusarkar.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-04-05T14:19:14.000Z","updated_at":"2024-07-14T01:28:35.000Z","dependencies_parsed_at":null,"dependency_job_id":"fbab1b87-6439-4399-b39c-4aa498404773","html_url":"https://github.com/mratanusarkar/Space-Invaders-Pygame","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mratanusarkar%2FSpace-Invaders-Pygame","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mratanusarkar%2FSpace-Invaders-Pygame/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mratanusarkar%2FSpace-Invaders-Pygame/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mratanusarkar%2FSpace-Invaders-Pygame/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mratanusarkar","download_url":"https://codeload.github.com/mratanusarkar/Space-Invaders-Pygame/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":233819585,"owners_count":18735302,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["arcade-game","atari","classic-game","game","nes","pygame","python","retro","space-invaders","video-arcade-games","video-game"],"created_at":"2024-12-20T18:29:41.258Z","updated_at":"2025-09-22T03:30:36.779Z","avatar_url":"https://github.com/mratanusarkar.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Space-Invaders-Pygame\n[![HitCount](https://hits.dwyl.com/mratanusarkar/Space-Invaders-Pygame.svg?style=flat)](http://hits.dwyl.com/mratanusarkar/Space-Invaders-Pygame)\n\nA pygame Implementation of the popular Classic Atari and NES Arcade games\n\nThis is a part of a series of Classic Arcade Games implemented in Pygames.\nlist of games in this collection:\n1. [Space Invaders](https://github.com/mratanusarkar/Space-Invaders-Pygame/) (my version)\n2. more coming soon . . .\n\n# Space Invaders\nThe classic [Space Invaders](https://en.wikipedia.org/wiki/Space_Invaders) was the first blockbuster arcade video game, responsible for starting the [golden age of video arcade games](https://en.wikipedia.org/wiki/Golden_age_of_arcade_video_games). It also sets the template for the [shoot 'em up](https://en.wikipedia.org/wiki/Shoot_%27em_up) genre, and influences nearly every shooter game released since then. \n\nThe classic Space Invaders 1978 was created by [Tomohiro Nishikado](https://en.wikipedia.org/wiki/Tomohiro_Nishikado) and was released by [Taito Corporation](https://en.wikipedia.org/wiki/Taito) in the year 1978.\n\n## Concept\nIn **my Implementation** of the game, the concept remains the same, i.e the *player spaceship* shoots the *aliens* or *monsters* and in doing so gain *points* followed by *level ups* and *increase in game speed* and *difficulty*.\n\nWhat differs from the classic implementation and the features are are listed below:\n* In each level, the number of *enemies* equals the *level number*, unlike the classic version in which there are 55 enemies each level.\n* After a certain number of *kills*, the *difficulty* goes up, resulting in a *speed increase* of the aliens. \n* The *enemy* keeps on respawning and will never die completely.\n* The *enemy* may shoot a *laser beam* depending on *random chance* or *probability*.\n* The *random chance* or *probability* of the enemy shooting you goes up as level increases.\n* The score is incremented on a successful kill and the value is based on the *level number* and *difficulty number*.\n\n## Features\nThe features of the game is as follows:\n* The player can be moved *left* or *right* using the `Left Arrow` and `Right Arrow` keys.\n* The game can be **paused** (v1.1.2 onwards) with `Enter key` or `Esc key`.\n* The player *levels up* with *increase in number of enemies* and a *level up sound* (v1.1.1 onwards)\n* The game has a **background music** (the classic Space Invaders music) which changes and becomes *more intense* with increase in *difficulty*.\n* The game pause has the classic sound effect\n* Each game object and every Interactions has sound effects.\n* The game has **key logging** feature and every input is **logged into the console**\n* The game also has **FPS Tracking** and Each **Frame Render time** in miliseconds and displays it in the game.\n\n## Gameplay\nHere is a short **gameplay** of the game at `Level 01` `Difficulty 01`:\n\n![gameplay L01D01](./assets/my_space_invaders-gameplay_L01D01.gif)\n\n\nA demo of in game **pause feature** in action at `Level 05` `Difficulty 03`:\n\n![pause demo](./assets/my_space_invaders-pause.gif)\n\n\nA look at **Game Over** Screen:\n\n![gameover](./assets/my_space_invaders-gameover.gif)\n\n\n**Logging** **KeyStrokes** and **Game states** on the console:\n\n![logging](./assets/my_space_invaders-logging.gif)\n\n## Installation\n### On windows:\n\nJust double-click the `runner.bat` file to launch the game, if you already have **python** and **pip** on your machine.\n\nYou can also manually install and run the game by following the manual process below:\n1. ensure that you have **python** and **pip** on your machine. If not, install it from [here](https://www.python.org/downloads/).\n2. clone the repo to a local directory or download it as zip and un-zip it.\n3. open windows command prompt (cmd) and enter the following commands:\n4. create a virtual environment `py -m pip install --user virtualenv`\n5. `py -m venv env`\n6. activate the virtual environment `.\\env\\Scripts\\activate`\n7. install the game dependencies from the requirements.txt file using the command `pip install -r requirements.txt`\n8. navigate to **main.py** and launch the game using the command `cd Space Invaders \u0026\u0026 python main.py`\n\nyou can skip creating a virtual environment if you wish and **ignore steps 4-6** but it is not recommended.\n\n### On Linux or macOS:\n\nNavigate to `main.py` and run `python main.py`, if you already have **python** and **pip** on your machine.\n\nIf not, get python and then run the main to launch the game!\n\n## References and Resources\nAll the resources used are mentioned below:\n\n#### Images:\n* [background.jpg](https://wallpaperscraft.com/download/galaxy_universe_stars_125862/800x600)\n* [alien.png](https://www.flaticon.com/free-icon/alien_389125)\n* [beam.png](https://www.flaticon.com/free-icon/bolt_414858)\n* [bullet.png](https://www.flaticon.com/free-icon/bullet_224681)\n* [enemy.png](http://getdrawings.com/space-invaders-icon#space-invaders-icon-70.png)\n* [rocket.png](https://www.flaticon.com/free-icon/startup_1067357)\n* [spaceship.png](https://www.flaticon.com/free-icon/space-invaders_744737)\n\n#### Music and Sounds:\n* [1up.wav](https://www.sounds-resource.com/nes/smb3/sound/768/)\n* [annihilation.wav](https://freesound.org/people/Robinhood76/sounds/187646/)\n* [enemykill.wav](https://freesound.org/people/SilverIllusionist/sounds/470585/)\n* [explosion.wav](https://freesound.org/people/IdkMrGarcia/sounds/446624/)\n* [gameover.wav](https://freesound.org/people/MattiaGiovanetti/sounds/483056/)\n* [gunshot.wav](https://freesound.org/people/pauliep83/sounds/34251/)\n* [laser.wav](https://freesound.org/people/THE_bizniss/sounds/39456/)\n* [pause.wav](https://www.sounds-resource.com/nes/smb3/sound/768/)\n* [Space_Invaders_Music.ogg](https://en.wikipedia.org/wiki/File:Space_Invaders_Music.ogg)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmratanusarkar%2Fspace-invaders-pygame","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmratanusarkar%2Fspace-invaders-pygame","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmratanusarkar%2Fspace-invaders-pygame/lists"}