I want to create a 2D game on Python with heavy user interface: windows, buttons, text input, etc. So far I've been using PyGame for a few simple games.
The game is a 2D MUD, with the standard rendering loop to draw stuff on the screen. I need the user interface to interact with the game entities like sales, blacksmith, etc.
I am looking for something like a mix of Pygame and wxPython/pyQT/pyGTK.
Which libraries can I use?
Fortunately, the Python arcade library makes creating a 2D game in Python accessible for many programmers! If you haven't already heard about it, the arcade library is a modern Python framework for crafting games with compelling graphics and sound.
Pygame supports only 2d games that are built using different sprites. Pygame is not particularly best for designing games as it is very complex to use doesn't have a proper GUI like unity but it definitely builds logic for further complex projects. The player can only move vertically.
1| Pygame. About: Pygame is an open-source Python library for making multimedia applications like games built on top of the excellent SDL library. This library is a combination of C, Python, Native and OpenGL. Pygame enables users to build fully featured games as well as multimedia programs with Python programming.
Pygame uses the Simple DirectMedia Layer (SDL) library, with the intention of allowing real-time computer game development without the low-level mechanics of the C programming language and its derivatives.
I would take PyQT with QGraphicsView or QGraphicsScene. Sadly there isn´t a Clanlib python binding like for perl and ruby. That would be, probably, the ideal choice.
You can use the popular Pyglet game library along with wxPython, the cross platform GUI library. An example of how to do this:
http://pyglet.googlecode.com/svn/trunk/experimental/wxtest.py
Additionally, if you want to use pure Pyglet, you can use Kytten, a pure Python GUI library built on the top of Pyglet.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With