Thursday, February 5, 2009


The framework we are using for Intelligent Design is called pyglet. Pyglet, in their words, is "a cross-platform windowing and multimedia library for Python".
We picked this framework for a couple of reasons:
  • It's oriented toward 2D. Most frameworks, engines, and libraries that exist on the internet are for creating 3D games. We looked into using one of these, and concluded that using a library that's made for 3D would be a bad idea. We'd be fighting the API to make it do what we want, and we'd have to keep track of three dimensions for everything when we would only be using two.
  • It's made for Python. As an example, another framework we were looking at was LÖVE. This framework did everything we wanted, even going so far as to have Box2D rolled in. However, the language required was Lua. We looked at Lua, and decided we didn't want to use it. Among other things, Lua starts arrays at 1 by default, which we didn't want to have to deal with for a semester.
  • It's simple and clean. There are some game frameworks that seem overblown and kludgy, and this isn't one of those. We considered using pygame, but it's way more complicated and has far too many features that we'd never use. Pyglet is a small download and doesn't even need to be installed to use.
However, no framework is perfect, and pyglet is missing a couple things we'd like to have. It doesn't do collision detection, and it has no built-in networking. Using pyglet with Rabbyt, a 2D collision detection library, seems to be a popular option, and we may do that. And Python already has a socket library with which to do networking, though we may look around for a networking library to avoid programming at such a low level.

At the moment, I am working on creating the cell programming interface. The player should be able to drag and drop and connect different blocks in order to program the cell to have different behaviors. So far I've got the dragging and dropping, and I'm going to be adding the connecting part shortly. Then we'll be moving into the exciting world of parsing! I'm excited.

No comments:

Post a Comment