Pyxel: A retro game engine for Python

(github.com)

276 points | by nateb2022 107 days ago

12 comments

  • krp 103 days ago
    A few years back I made some pyxel snippets for students in a class I was teaching, to help get them up to speed on using it: https://github.com/kris-classes/pyxel-snippets

    They may be useful to someone here if not too much has changed with pyxel since then.

    • dr_kiszonka 103 days ago
      This is very useful. I tried Pyxel a few years ago, but it wasn't documented well. There were some resources in Japanese, but I don't know it, unfortunately.
  • halfcat 103 days ago
    These retro game engines are so much fun. Takes me back to the days of mode 13h.

    Pyxel is (I think) unique among Python game engines in that it can run on the web.

    Some others I’ve played with are PyGame and Arcade, mostly geared toward 2D, but you can see some impressive 3D examples on the youtube channel DaFluffyPotato.

    Ursina is another that’s more 3D, fairly expressive, and runs fairly well for being Python.

    I do feel like I’m going to be forced to cross over into something more powerful to build a real game though. Either Godot or Unity.

  • erremerre 103 days ago
    I made my first video game with it. A pong game you can play, but it has not been polished. While the menu works, is yet unable to show the selected option. And the IA to play against are either too easy or brutal.

    https://blog.rmrubert.eu/miniproyectos/rpong/rpong.html

    • grigy 103 days ago
      This is cool, I like the dynamics. Is the source code available? I'm curious how much effort went into this.
      • erremerre 102 days ago
        Not available, the source code is an absolute mess. It would only be useful as how you should not make a game.
  • 999900000999 103 days ago
    Looks very cool.

    I absolutely love that it uses a language I actually know instead of some niche thing or a DSL.

    I'll have to check it out when I have some spare time.

  • Razengan 103 days ago
    I really wish there was a modern "computer console" like the Commodore 64 or Sinclair Spectrum of old, where you could boot straight into a programming environment.

    Something comparable to the Nintendo SNES or DS's hardware capabilities, which seemed like the perfect sweet spot between artistic freedom and "helpful" limitations which actually improved creativity by lowering complexity.

    • keyle 103 days ago
      One could argue the opposite. There are countless 'computer console' available at various low price ranges.

      The closest thing today is RaspberryPI, and boot to a linux in text mode, you're basically there.

      What is more difficult to find is the combo hardware/software, but the Pi 400 includes keyboard and a mouse comes with as a kit.

      Just like in the old days, find a (~TV) cheap LCD monitor and plug and play.

      And you have hundreds of games for free, thousands possibly with emulators etc. And you can program in virtually every languages on the planet.

      If anything, what you have now paralysis by choice. There is just too much you can do with a basic computers, so you wind up on youtube and social medias instead of being bored with 1 compiler and 1 book.

      ref: I grew up on ZX Spectrum+! :)

      • asyx 103 days ago
        And you have the option to branch off into any other kind of development. A C64 Style clone is mostly nostalgia. A raspberry pi is presenting you (or your children) with dozens of ways to learn employable skills project based and in a fun way.
    • Hackbraten 103 days ago
      You might like the Commander X16. [1]

      [1]: https://www.commanderx16.com/

      • Gormo 103 days ago
        Also the Foenix C256: https://c256foenix.com/

        These kinds of projects are becoming more and more common in retrocomputing circles.

    • exitb 103 days ago
      This might be a bit more complex. We like to remember that we were creative in C64 BASIC, but it is really too slow for any sprite-based game development. What's different between then and now is that changing the frame color used to be an event you told all friends about.

      An intersection of simple and impressive - I feel like Raspberry Pi Pico and the likes embody this spirit nowadays.

    • robxorb 103 days ago
      You might enjoy the Pimoroni PicoSystem, or its HDMI bro, the PicoVision:

      https://shop.pimoroni.com/products/picosystem?variant=323695...

      https://shop.pimoroni.com/products/picovision?variant=410489...

      (Not affiliated nor trying to sell it, the shop is just the best link for information.)

      EDIT: Also it's not quite boot into IDE, but the vibe of both is similar in every other way.

    • shakna 103 days ago
      Picotron [0] is looking like that. I am watching that project closely right now.

      [0] https://www.lexaloffle.com/picotron.php

    • pindab0ter 103 days ago
      Not quite what you meant, but close enough for a mention: The Playdate.

      It's a platform specifically made for games (as opposed to a Raspberry Pi for example), has a library of great games and is ostensibly easy to develop for.

    • b800h 103 days ago
      The ZX Spectrum Next is exactly this.
    • ramses0 103 days ago
      Also take a look at Circuit Playground Express. https://learn.adafruit.com/circuitpython-made-easy-on-circui...

      It's a "computer" that boots straight to your program. MicroPython (I even did it with TinyGo), and you can make lights blink! But seriously... there's some very interesting stuff with it, and you can also add on another chip that lets you rock and roll with motors, speakers, etc. https://www.adafruit.com/product/3093

    • phasel0ck 103 days ago
      check out the Mega65: https://www.mega65.org
  • marksbrown 103 days ago
    An absolutely fantastic engine in my experience. I've used it with students (rather than pygame) due to its bare bones nature. I love how with a simple class structure of update and draw, students can gain a tangible grasp of oop concepts as well as implementing their own ideas. 10/10
  • dinozarw 103 days ago
    pico-8: Python Edition
  • VagabundoP 103 days ago
    This is a thing of beauty. Might try and make a little game with my teen kid.
    • grugagag 103 days ago
      Also give Pico-8 and Tic-80 a chance.
  • extrabajs 103 days ago
    I feel like there’s way too much color for this to be ‘retro’. It seems you are limited to using 16 colors at once, but those colors are drawn from a 24-bit palette unless I’m missing something.
  • ilikehurdles 103 days ago
    Finally, a python game engine capable of running at 60fps ;)
  • AinoSpring 103 days ago
    Someone needs to make a python game engine counter
  • LarsDu88 103 days ago
    Python AND Rust so it doesn't run like total shiite
    • vgalin 103 days ago
      Python library with Rust backend*