Game Development

Awesome game development libraries.

2D games need a game loop: pygame-ce has you write it; Arcade runs it. Ren'Py is built for visual novels, as Panda3D is for 3D in Python game development.

How to choose:

  • A game loop you write and control yourself: pygame-ce
  • A game loop, physics, and screen switching built in: Arcade
  • 3D games, visualizations, and simulations: Panda3D
  • Visual novels and other writing-heavy games: Ren'Py
  • Windowing, OpenGL graphics, and media with no dependencies: pyglet
  • Code already written for pygame: pygame-ce

Listed in editorial order, grouped by use case. Click a column header to re-sort the whole list.

Press / to search. Tags open their category. Click a row for details.

Search and filter

Results

Row number Tags

3D Engines 1 project

3D game engine developed jointly by Disney and contributors from around the world.
panda3d/github.com/panda3d/panda3d /5,262 stars /

Game Frameworks 4 projects

A cross-platform windowing and multimedia library for Python.
pyglet/github.com/pyglet/pyglet /2,227 stars /
An actively developed drop-in replacement with new features and performance improvements (pygame fork).
Pygame is a set of Python modules designed for writing games.
pygame/github.com/pygame/pygame /8,994 stars /
An easy-to-use library for creating 2D arcade games.
pythonarcade/github.com/pythonarcade/arcade /2,095 stars /

Visual Novels 1 project

A visual novel engine.
renpy/github.com/renpy/renpy /6,952 stars /

Game Development guide

pygame-ce installs as pygame-ce and still imports as pygame. It gives you full control of program execution: you write the loop that handles events, draws the frame, and flips the display. pygame-ce is LGPL, which still allows closed-source and commercial games; only changes to pygame-ce itself must be released under a compatible license.

Arcade is built on pyglet, and it's ideal for beginning programmers or anyone who wants 2D games without learning a complex framework. Give each screen its own arcade.View subclass that overrides on_draw() and on_update(), then hand control to arcade.run(). Draw sprites through a SpriteList, the only way to draw a sprite, which batches them for you. For movement and collisions, start with the built-in physics engines: a simple one for top-down games, and a platformer one with gravity and moving platforms.

Panda3D is a C++ engine scripted in Python, and its manual says you must be a skilled programmer to use it. Subclass ShowBase, which opens the 3D window, and call run() once, as the last line. A model shows up only once it's attached to the scene graph, a tree rooted at render.

To use Ren'Py, you download it and work in its launcher, which creates, edits, and runs your projects. Write the story in its script language, and reach for its screen language and Python when you need custom interfaces or game logic.

pyglet is a windowing and multimedia library with no external dependencies, for games and other visually rich apps. Attach handlers like on_draw() with @window.event and call pyglet.app.run(), since writing your own event loop is generally not necessary. Draw many sprites in a Batch, which the docs strongly recommend.

Know a project that belongs here?

Tell us what it does and why it stands out.