pygame projects
16/05/2025
Pygame
As a long time gamer I’ve entertained the idea of making games, on and off, over the years. I’ve been drawn more to Machine Learning, Data Science, and a variety of apps, until I got my head around the python package pygame 🙂
Pygame is a set of Python modules designed for writing games. It is written on top of the excellent SDL library. This allows you to create fully featured games and multimedia programs in the python language. Pygame is highly portable and runs on nearly every platform and operating system.
Looking for inspiration, I’ve drawn on favourite classic games of my youth, and other challenges that I’ve considered over time
I’ve published the code, together with executable files, to my GitHub page, where I’ll continue to update them, and thought I’d share info of them here, together with other bits of code that I’m finding useful, pyinstaller I’m thinking of you ;p
Games that I’ve pushed to Git
Dinghy Sailing Race
Welcome to Dinghy Sailing Race! This is a 2D sailing simulation game built with Pygame where you navigate a dinghy around a randomly generated course, competing to get the best race time. Manage your sail trim, use the wind to your advantage, avoid sandbars, and round the buoys to complete laps.
This was the first idea I played with, motivated by the purchase of a RC Boat, I’m curious to see if I could build a Machine Learning model, to sail the boat competently. Before building the model in the real world I decided to see if I could create a simple game, where the in game boat would experience simplified sailing physics.
Rally Racer
Rally Racer is an exciting top-down 2D racing game built with Pygame. Players control a car and compete against AI opponents on procedurally generated tracks. The game features various challenges including dynamic AI with varying difficulty levels and randomized performance for a unique race
I’ve wanted to create a top down driving game for a while, and this was initially built off the code of the Dingy Race, with many iterations it became it’s own game, and I introduced several different variables that can be changed before beginning a race, including AI opposition!
This is the largest of the game projects, so followed best practice principles, and split the code up from the single python script, making it easier to maintain, bug fix, and update.
Wharf Manu
Wharf Manu is a simple and fun diving game where the goal is to perform the best “manu” off the wharf! You’ll be judged on your entry into the water – aim for the biggest splash. Somersaults will also impress the judges!
Definition:
Manu is a term in Hindu mythology that refers to the progenitor of humanity and the first man. It also denotes a title for the fourteen rulers of the earth during each cosmic cycle, known as a kalpa.
It’s not about that though:
The manu bomb – a classic Kiwi pastime and nationwide phenomenon – is more than just a splash, it’s a way of life, according to manu ambassador Hads Te Huia (Ngāti Maniapoto).
The Manu: a generational Kiwi tradition, a way of life
I wanted to create something kiwi, and I couldn’t think of anything that encapsulates a NZ summer, like doing manus at the local swimming hole.
The goal of a manu is to create the biggest splash, achieved by hitting the water in a V shape, bottom first. The scoring of the game is based on diving, marks out of ten from each judge, bigger the splash, higher the points, bonus for somersaults. 5 scores given, highest and lowest removed. The sum of 3 turns gives the score for the game.
Sisyphus
“The Trial of Sisyphus” is a challenging arcade-style game inspired by the ancient Greek myth of Sisyphus. Experience the eternal struggle as you take on the role of the cursed king, doomed to push a massive boulder up an ever-steepening hill, only for it to inevitably roll back down.
The idea of this game isn’t my own, I came across it years back, created by the talented, inspirational genius Pippn Barr.
I love the meaningless nature of the game, and how failure is the only ending. I like how there’s not much at all to this game, and how the simplicity is framed.
Horace Skis Again!
“Horace Skis Again!” is a fun, fast-paced arcade-style skiing game. Take control of Horace as he speeds down a snowy mountain, navigating through treacherous trees and challenging flag gates. The goal is to ski as far as possible, racking up points by successfully passing through gates, while avoiding obstacles. The game features a dynamic parallax background with mountains, hills, snow, and even foreground clouds for an immersive experience!
It’ll take few guess to correctly identify what motivated this game, a simple recreation of the classic skiing game, I first encountered on school BBC’s over 4 decades ago. I played with parallax scrolling to see if I could get more of a feeling of movement, lemme know what you think.
Defender
A fast-paced, side-scrolling vector shooter inspired by the arcade classic “Defender.” Navigate a vast, looping world, protect humanoids from alien abduction, and blast waves of increasingly challenging enemies.
It wasn’t actually the game that directly inspired this recreation, but the Beastie Boys lyrics, in their song Body Movin’: ” And if you play Defender, I could be your hyperspace”
No hyperspace yet, but an enjoyable shooter, zap the aliens across the continuous map, bonus points for not allowing the ships to take the humans off planet.
PyThrust
PyThrust II is a classic arcade-style game where you pilot a spaceship through challenging levels. The objective is to navigate your ship, collect beacons, destroy obstacles, manage fuel, and land safely to advance. The game features increasing difficulty with more obstacles in later levels and keeps track of high scores.
Another choice brought to you from the BBC Micro, this isn’t as detailed as the original (yet!), shoot the static targets, avoid the moons, while fighting gravity. No time limit, and you can recharge fuel by landing upright on the planet.
I may create more detailed pages of the above games, or maybe just the ones I develop further, I’m considering making Wharf Manu into a app, off to explore the Internet Arcade for ideas 🙂