Skip to main content

A powerful Python library that combines AI image generation with Pygame Zero enhancements. Create stunning games with AI-generated assets and streamlined development workflow.

Project description

PGZPro - AI-Powered Game Development Toolkit

A powerful Python library that combines AI image generation with Pygame Zero enhancements. Create stunning games with AI-generated assets and streamlined development workflow.

🚀 Features

AI Image Generation

  • Flux Model Integration: Generate high-quality images using G4F's Flux AI model
  • Smart Prompt Translation: Automatic translation of non-English prompts
  • Transparent Backgrounds: Create PNG images with transparent backgrounds
  • Custom Dimensions: Generate images in any size up to 1024x1024 pixels

Pygame Zero Enhancements

  • Window Centering: Automatically center your game window on any screen
  • Seamless Integration: Works perfectly with Pygame Zero ecosystem
  • Desktop Notifications: Display beautiful notification messages

🛠️ Core Commands

Window Management

import pgzpro  # MUST be imported BEFORE pgzrun

pgzpro.center()           # Center the game window on screen
pgzpro.no_logging(True)   # Disable debug logging (optional)

import pgzrun

AI Asset Generation

# Generate game background (automatically fits screen)
background = pgzpro.bg_generate("fantasy forest with mountains")

# Generate character with transparent background
character = pgzpro.actor_generate("hero knight", "60x80")

# Generate game objects
crystal = pgzpro.actor_generate("magic crystal", "40x40")

Desktop Notifications

# Show notification message (auto-closes after 3 seconds)
pgzpro.message("Game started!")

# Custom notification with colors and duration
pgzpro.message("Level completed!", text_color="white", bg_color="green", duration=5.0)

# Quick notification (1 second)
pgzpro.message("Item collected!", duration=1.0)

⚠️ AI generation needs active internet connection

🆕 What's New in Version 1.1.0

  • Notification System: Added new message() function for desktop notifications
  • Correction of defects: Fixed cleaning of temporary files

📦 Installation

pip install pgzpro

🔄 Updating the Library

pip install -U pgzpro

or

pip install --upgrade pgzpro

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

pgzpro-1.1.1.tar.gz (9.1 kB view details)

Uploaded Source

Built Distribution

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

pgzpro-1.1.1-py3-none-any.whl (9.4 kB view details)

Uploaded Python 3

File details

Details for the file pgzpro-1.1.1.tar.gz.

File metadata

  • Download URL: pgzpro-1.1.1.tar.gz
  • Upload date:
  • Size: 9.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for pgzpro-1.1.1.tar.gz
Algorithm Hash digest
SHA256 b0234d9f4c039663a1e020bed03d26708a44c8538b823eab27d136c3005f0d0b
MD5 e088a577ce208daa7760776652313afa
BLAKE2b-256 7fee4109743dc1df1c209f5bcb9647a2aad403b62f94e3423e12b5c7d334ee5a

See more details on using hashes here.

File details

Details for the file pgzpro-1.1.1-py3-none-any.whl.

File metadata

  • Download URL: pgzpro-1.1.1-py3-none-any.whl
  • Upload date:
  • Size: 9.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for pgzpro-1.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e07c919b7e18558453d3ed1973ee17631c735f43afae6c33dbf1cbc32ba2a3f9
MD5 a7b2d22056b85e31a4b223bf99ef9e15
BLAKE2b-256 233a78c2a7a8aad7e94d5da669cea006384bbab6b228603ce802c2ce1878a553

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