diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..8c9e782 --- /dev/null +++ b/.gitignore @@ -0,0 +1,108 @@ + +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +wheels/ +*.egg-info/ +.installed.cfg +*.egg +MANIFEST + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*.cover +.hypothesis/ + +# Translations +*.mo +*.pot + +# Django stuff: +*.log +.static_storage/ +.media/ +local_settings.py + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ + +# PyBuilder +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# pyenv +.python-version + +# celery beat schedule file +celerybeat-schedule + +# SageMath parsed files +*.sage.py + +# Environments +.env +.venv +env/ +venv/ +ENV/ +env.bak/ +venv.bak/ + +# Spyder project settings +.spyderproject +.spyproject + +# Rope project settings +.ropeproject + +# mkdocs documentation +/site + +# mypy +.mypy_cache/ + +# vscode settings +.vscode \ No newline at end of file diff --git a/README.md b/README.md index 70c49df..7066f7d 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,15 @@ # Flappy-Bird The classic game of flappy bird made with python and pygame. + +## Installation +Clone this repository and ensure you activate `virtualenv`. This project assumes you have `Python3` installed. + +### Install the dependencies + +`pip install -r requirements.txt` + +### Run the project + +` python flappy_bird.py ` + + diff --git a/flappy_bird.py b/flappy_bird.py index 9880c45..7903bdc 100644 --- a/flappy_bird.py +++ b/flappy_bird.py @@ -12,8 +12,9 @@ import time pygame.font.init() # init font -WIN_WIDTH = 600 -WIN_HEIGHT = 800 +# adjusted resolution to be able to run on Mac OS Catalina +WIN_WIDTH = 1200 +WIN_HEIGHT = 1200 PIPE_VEL = 3 FLOOR = 730 STAT_FONT = pygame.font.SysFont("comicsans", 50) diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..f63a640 --- /dev/null +++ b/requirements.txt @@ -0,0 +1 @@ +pygame==2.0.0.dev6