A few weeks ago I was asked if I’d be keen to go to Kiwi Pycon (a Python conference in Dunedin, New Zealand). I decided it would be an interesting experience even though my Python knowledge is a bit lacking. So as an after-work project my colleague Yosan and I decided to put together a small game to help us learn the language. This article covers our initial experiences putting everything together.

The plan

As with other languages I’ve learned I typically like to develop an application which involves a handful of functions such as reading files, networking, user input and visuals. This forces me to become familiar with libraries and language functions which gets me up to speed in a way that re-implementing algorithms and completing tutorial projects would not. It also forces me to understand a bit about Python’s environment with regards to installing dependencies and creating releases.

We looked up a few libraries related to game creation and networking and decided to use pygame as that seemed to provide a functionality that would remove a lot of the tedium from development. It also looked like Python had a range of libraries for networking so we decided to figure it out when we got to it.

Installing Python

Python itself was relatively easy to install. We just took the auto installer from the website and had the runtime ready within a minute.

#gamedev #python

Learn Python using Gamedev
1.50 GEEK