Skip to content
This repository was archived by the owner on May 11, 2025. It is now read-only.
/ pysnake Public archive

A retro-style, fun and addictive Snake Game built in pure Python using the curses library

Notifications You must be signed in to change notification settings

kelwynOliveira/pysnake

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

Python

🐍💻 PySnake — Terminal Edition

A retro-style, fun and addictive Snake Game built in pure Python using the curses library!
Move fast, eat fruits, avoid walls and your own tail — old school fun, directly from your terminal.


✨ Screenshots

pysnake


🎮 How to Play

The rules are simple:

Key Action
↑ / ↓ / ← / → Move the snake
Eat 🍋 symbol Grow your snake
Avoid Hitting walls or yourself

The longer you survive, the higher your score! 🍎

🧰 Difficulty Levels

Level Speed Challenge Level
1 Slow 🐢 Beginner
2 Medium 🚶‍♂️ Casual
3 Fast 🏃 Intermediate
4 Faster ⚡ Hard
5 Extreme 💀 Snake Master

⚙️ How to Run

1️⃣ Create a virtual environment (optional but recommended)

For macOS / Linux:

python3 -m venv .venv
source .venv/bin/activate

For Windows:

python -m venv .venv
.venv\Scripts\activate

2️⃣ Install dependencies (for windows)

pip install windows-curses

⚠️ On Windows, you need windows-curses for terminal compatibility.


3️⃣ Start the game!

python pysnake.py

4️⃣ Stop the game

To deactivate the virtual environment when you're done:

deactivate

🧠 Project Overview

  • 🐍 Classic Snake Game logic.
  • 🎯 Score-based — collect as many fruits (🍋) as possible.
  • ⚡ Adjustable difficulty: choose your speed before the game starts.
  • 💻 Fully terminal-based, no GUI dependencies.
  • ✅ Cross-platform friendly: Windows, macOS, Linux (with curses).

📂 Project Structure

pysnake/
├── .venv/ (optional virtual environment)
├── assets
├── .gitignore
├── pysnake.py
└── README.md

💡 Notes

Remember:
You only deactivate the virtual environment when you're done running the project and don't need to use its dependencies anymore.
Activate ➡️ Play ➡️ Then deactivate.
Activating and immediately deactivating won't launch the game — run it first, enjoy, then exit!

About

A retro-style, fun and addictive Snake Game built in pure Python using the curses library

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages