Skip to main content

A python library to allow you to play snake on anything!

Project description

anysnake

anysnake is a super basic snake game that allows you to play it on any device with a Python API and a matrix display. This could be LED's on the front of a network switch, oscilloscope or even plumb it straight into pygame.

Installation

Install via pip:

pip install anysnake

Or install from source:

git clone https://github.com/yourusername/anysnake.git
cd anysnake
pip install -e .

Usage

from anysnake import SnakeGame

def output(matrix):
    """Get matrix data from SnakeGame"""
    print('\n' * 10)
    print(matrix)

snake = SnakeGame(grid=(6, 6), interval=1, start_len=2, callback=output)
snake.start()

Contributing

Contributions are encouraged. Try this and send your crazy snake games to feature in our anysnake project. For any issues please open an issue or submit a pull request on GitHub.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

anysnake-0.1.0-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file anysnake-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: anysnake-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 4.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for anysnake-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b1d8b0966ae48e2cbb58fff9c0029319a137473162bb8139f27b89b1c42b0b60
MD5 f58612503bdf498c075ea0a50549a970
BLAKE2b-256 d8e3d0e1d58fbf0b9792eacc9396ad7dbc8f57e891758636a955c6706ae0c998

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page