Skip to main content

Tiny fantasy console inspired by TIC-80

Project description

📦 PIX-8 — Tiny Fantasy Console

PIX-8 is a minimal, retro-style fantasy console written in Python.
It lets you create tiny games with a simple PEP-8-inspired Python cartridge format.


⚡ Features

  • 128×128 pixel display

  • 16-color palette

  • Simple drawing API: cls(), pset(), rectfill()

  • Input: arrow keys + Z/X as buttons

  • PEP-8–style cartridges (init(pix), update(pix), draw(pix))

  • Runs as a single Python file (pix8.py)


🏁 Installation

git clone <repo-url>
cd pix8
pip install .

Or if you just want to run it locally without pip:

python pix8.py game.py


🎮 Writing a Cartridge

Create a Python file, for example game.py:

metadata = {"title": "Tiny Demo"}

def init(pix):
pix.x = 60
pix.y = 60

def update(pix):
if pix.btn("left"):
pix.x -= 1
if pix.btn("right"):
pix.x += 1

def draw(pix):
pix.cls(1)
pix.rectfill(pix.x, pix.y, 8, 8, 8)

Run it:

pix8 game.py


🔑 API Reference

Function Description
pix.cls(color=0) Clear the screen
pix.pset(x, y, color=7) Draw a single pixel
pix.rectfill(x, y, w, h, color=7) Draw a filled rectangle
pix.btn("left") Check if a button is pressed (left, right, up, down, a, b)
pix.flip() Update the screen and tick FPS

📄 License

MIT License — free to use, modify, and share.

Project details


Download files

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

Source Distribution

pix8-0.0.6.1.tar.gz (4.9 kB view details)

Uploaded Source

Built Distribution

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

pix8-0.0.6.1-py3-none-any.whl (5.4 kB view details)

Uploaded Python 3

File details

Details for the file pix8-0.0.6.1.tar.gz.

File metadata

  • Download URL: pix8-0.0.6.1.tar.gz
  • Upload date:
  • Size: 4.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.2

File hashes

Hashes for pix8-0.0.6.1.tar.gz
Algorithm Hash digest
SHA256 a57bad825dc09621a1eb0263b04283f16ad31de69af91d4b298a9c38c1bc0cb0
MD5 b89be88010aac965c88c558297d8aa79
BLAKE2b-256 ab3e34e8e88af4ef027eab77d214776aa69d12ee78ca0ec28147819ff4b60016

See more details on using hashes here.

File details

Details for the file pix8-0.0.6.1-py3-none-any.whl.

File metadata

  • Download URL: pix8-0.0.6.1-py3-none-any.whl
  • Upload date:
  • Size: 5.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.2

File hashes

Hashes for pix8-0.0.6.1-py3-none-any.whl
Algorithm Hash digest
SHA256 55d67c2bafdd70cdb6199e013475593159c887ee32698077e9d26b411facca0b
MD5 1777b2fd0ee490ddfb29d6966f15d54e
BLAKE2b-256 17ac35115f88cf2ef867b7ca5d9dfd08968b09189cee7e94f476e9f4fb6587bf

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