Google’s C++ testing library has a nice syntax for registering tests,
without needing to remember to add the tests to some central index.
This article will show how to use macros to allow the creation of tests
using only the following code:
I wrote a raytracer and a rasteriser as part of my university course.
The raytracer supported features such as indirect lighting, reflection,
refraction, and a photon mapper capable of simulating the final positions of
60,000,000 photons in a few minutes (and quite a few GBs of RAM).
I wrote a Bash script to sort git commits into buckets, to be used as the first
step of making a change log. It supports rewording commit messages, can be
stopped and resumed, and supports automatic filtering based on keywords
During the second year of university, I created a kernel for the ARMv7
instruction set. I went above and beyond what was required on this project,
achieving a clean design and features such as a blocked process queue, piping,
kill, and a simple filesystem. This was my favourite coursework so far. I found
it very interesting to learn about and implement the things that we take for granted
For the last two years, I have been working on a very ambitious game. The game
is a top down sandbox with multiplayer support. I’m aiming towards a city-based
game, where players can wander around a procedurally generated city.
One of the main reasons I started creating this game is to learn about multiplayer
networking at a low level - client-side prediction, server-side reconcilliation,
cheat preventation, and reducing the visual effect of latency.
Github pages is a very convenient way to host both personal websites,
and project websites. Websites are linked to a git branch or repo, and
update when pushed too. Github pages supports custom domains as well!
Whilst Github Pages supports HTTPS for github.io websites, it does not
support HTTPS when using a custom domain.
It’s very hard to debug a crash when no stack traces are printed.
It becomes a case of manually trying to find the error.
Doing something useful
Error: Expected } near ;
ES6 promises doesn’t seem to offer the functionality to change this,
and bluebird has on[Possibly]UnhandledRejection, which can only be
used if you don’t add a .catch() case to the promise. There is no global
callback for a rejection unless it’s unhandled. To workaround this, we’re
going to need to override the method which runs the callbacks. This is a
little hacky, and relies on the library not changing - but it’s better than
First, if you haven’t already, install Bluebird.
Next, make a file somewhere (perhaps called bluebird.js) with this as its
Alternatively you could just print reason.stack if it exists, however I prefer
a full crash whilst debugging. You could also make it possible for promises
to declare whether they should throw errors - similar to the throw keyword
in Java - and print out the stack rather than crashing in that case.
I created a very short C++ snippet to accumulate a series of Mats into
a single Mat strip. It works like acc = acc + m - a new mat is added to the
accumulator each time, then stored in the accumulator again.
Usecase: shells dropping in sync with firing, fake bullets, etc
You must use a particle emitter to create particles, however this doesn’t mean
it’s impossible to create single particles on command. You can create a particle
emitter which simply adds particles from a queue to the system
The above allows you to use the push functions to emit particles.
Here is an example of it in use:
This tutorial will show you how to create a new MonoDevelop solution and project,
and how to properly connect it to RimWorld. You’ll need to have an installation
of Mono that supports .NET 3.5 -
here is a tutorial on how to install it.
This tutorial will show you how to install Mono and Monodevelop in order to
develop .NET 3.5 projects. This is useful when writing C# assembly mods
for Unity engine based games, such as RimWorld, as they tend to require
Now that Github supports unlimited private repos in all plans, you might as well
keep things all together (although definitely have backups elsewhere incase
Github is DDOS’d again, dies or goes evil). Simply change “rubenwardy” to your
username and “XXXX” to a
personal access token with “repo” checked.
Also make sure you have an SSH key for Github.