A sound-controlled terminal-based rhythm game
Project description
K-AIK▣ is a sound-controlled terminal-based rhythm game.
⣿⣴⣧⣰⣤⣄ [00000/00032] □ □⛶ □ ■ ■ □ □ ■ ■ □ [ 0.9%|00:01]
Getting Started
Install PyAudio
Installing PyAudio via pip may encounter some problems, which is caused by the external dependency of PyAudio. Our recommendation is to use Anaconda, it can solve all problems. After installing Anaconda, just run
conda install -c anaconda pyaudio
If you have issue (no sound or error while playing), see next section.
Install K-AIKO
You can install it from PyPi
python -m pip install K-AIKO
Or fetch from source directly
git clone git@github.com:worldmaker18349276/K-AIKO cd K-AIKO python -m pip install .
Play
Now you can play K-AIKO
kaiko
Or
python -m kaiko
Install PyAudio Without Using Conda
The PortAudio provided by Annaconda conda-forge channel seems have some issues, see https://github.com/ContinuumIO/anaconda-issues/issues/4139. The solution is simple: don’t use Annaconda. Before install PyAudio, you should uninstall them in conda
conda remove pyaudio
Linux
Install PyAudio via apt
sudo apt-get install python3-pyaudio
Or install PortAudio first
sudo apt-get install python-dev portaudio19-dev python -m pip install pyaudio
Mac
Install portaudio using homebrew (or method of your choice)
brew install portaudio
Create $HOME/.pydistutils.cfg using the include and lib directories of your portaudio install
[build_ext] include_dirs=/Users/jrobert1271/homebrew/Cellar/portaudio/19.20140130/include/ library_dirs=/Users/jrobert1271/homebrew/Cellar/portaudio/19.20140130/lib/
Then in your virtualenv
pip install --allow-external pyaudio --allow-unverified pyaudio pyaudio
Windows
Download the wheel on this site https://www.lfd.uci.edu/~gohlke/pythonlibs/#pyaudio.
Choose PyAudio‑*‑win32.whl (the newest one) if you use 32 bit, or PyAudio‑*‑win_amd64.whl for 64 bit. Then go to your download folder
cd <your donwload path>
Then, install by wheel
python -m pip install <PyAudio's wheel file>
Tests
You can prepare environment for testing
git clone git@github.com:worldmaker18349276/K-AIKO cd K-AIKO conda env create -f environment.yml --prefix ./envs
Remember to activate environment before testing
conda activate ./envs python -m kaiko
Publish
python -m build --sdist --wheel . twine upload dist/* git push origin master --tags
Compatibilities
In theory, It is compatible to all terminals support ANSI escape code.
Tested terminals:
GNOME terminal (Linux)
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.