[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Simple board game GUI framework

On 11.09.2017 12:58, Paul Moore wrote:
> I'm doing some training for a colleague on Python, and I want to look
> at a bit of object orientation. For that, I'm thinking of a small
> project to write a series of classes simulating objects moving round
> on a chess-style board of squares.
> I want to concentrate on writing the classes and their behaviour, and
> not on display issues, but I would like it if the resulting program
> was reasonably interesting. To that end, I was thinking of putting
> together a frontend that displayed the objects moving round on a board
> (rather than, for example, just printing out lists of co-ordinates).
> I'd build the frontend, then my student could write the object classes
> and drop them into the framework.

Maybe not exactly what you are asking for, but something I thought about 
for a Python class earlier this year: There are several Minecraft mods 
that let you interact with the game from Python. Of course, Minecraft 
itself is Java code, but it's a prime example of OOP and you are getting 
a very sophisticated and fully tested display engine for free. It's a 
bit complicated to get started with (which eventually made me postpone 
this experiment to next year's class), but I think it may be a lot of 
fun, especially if you've played Minecraft before. Here's a link to get 
you started: http://www.instructables.com/id/Python-coding-for-Minecraft/