Back in October, I attended a workshop from GC Digital Fellow teaching attendees how to use pygame. I had previously used RenPy, a Python framework for writing visual novels, but hadn’t had much luck trying to learn game engines such as Godot. Before the workshop, our instructor, Zach, provided us with a GitHub link with the assets we’d need as well as instructions to download the pygame software. In addition to the images we’d need to create our game – a Frogger clone – we’d find a copy of the finished code, which we would use as a reference when building the game from scratch.
On the day of the workshop, Zach patiently took us through developing each aspect of the game, from the basic variables that we’d need to plug in later to a basic class for objects in the game to character movement. Along the way, he would mention additional measures that we could take on our own time, such as sealing off all four sides of the screen from player movement (meaning that the player can’t go “out of bounds” so to speak). I would often find myself detouring to tweak aspects of my game so that I could gain a deeper understanding of how each part of the code worked.
While we didn’t have time to get through the whole game, we had set up each element of the game and had the final code to reference after the workshop ended. At the end, we were challenged to tweak this final code to create a more interesting game, which I wound up doing. I took the challenge to have the treasure chest (the goal to complete the level) appear in a random position after the first level. I had the enemies increase in speed as the levels progressed at different rates, and moving in different directions. I also changed their movement pattern to loop around when they left the screen rather than bounce back and forth. I added a level counter, and had the game loop back to the first level in the event that the player loses. Through the workshop, I had the foundation and freedom that I needed to truly play and explore in the software.
This workshop, which uses free software and shares assets and instructions through a public repository on GitHub, made me think of our previous discussion on Open Educational Resources. The materials are freely available, and even without the guidance of the workshop, people can learn how to get started with pygame. Furthermore, although the project itself starts out fairly linearly, this form of instruction allows the participants the freedom to pursue their own interests with the software. For me, this is the best way to learn programming – to be able to not only ask your own questions, but answer them as well.



