top of page
Game Genre

Third person action platformer


14 weeks of half speed

Team size




My role

Gameplay Programmer - Enemy

My contributions
  • Boomer (Ranged enemy)

  • Rat spawners

  • Rat nest "boss"

  • Reworked sound engine

  • Prediction for grenade aiming.

Boomer (Ranged Rat)

Worked primarily on the behaviour tree for the ranged enemy rat that we named Boomer.

Most of it was pretty standard but because it attacked by spitting it had an arcing attack. One of the things I did was calculate the speed needed for the arc to always line up with the players position, taking height differences into account as well. The projectile only gets a starting force added to it through PhysX which then handles everything.

The video to the left shows the rat in a test scene spitting at the player with a few different height differences.

Rat spawners

The rat spawners are exactly what the sound like. The are structures that spawn rats. They have a set amount of rats they can have active at the same time as well as a set amount of each type of rat. They have a pulsating weak point that will disable the spawner if destoyed. The actual point of the appearing rats can also be set if the default position is not good enough.

Before they spawn a rat they make sure the area is clear from obstacles that would be an issue. 

In this video is an example from my test scene. Sadly it was taken at a bad time where we had a few issues with enemy movements so the rat won't move away from the starting position but it does show that no additional rat spawns while the existing one is


If time allows I will try to replace the video with a better one.

As our engine is constantly being reworked for each projects different requirements we used PhysX for this project rather than our old simple collision system. This resulted in a few challenges because of features not existing but my fellow programmer Alexander Rosendahl quickly added a function to detect if any colliders are within an area and a system to filter them.

Rat nest

The rat nest is our version of a boss.


It is a wave spawner that spawns a new wave each time a weak point is destroyed. The idea is that if the player doesn't fight the spawning rats and just go for the weak points they will get swarmed.

Each weak point has to be destroyed in the correct order and you can see which one is the currently active one because only the active one will pulsate. I can't say I showed it off in this video so you will have to take my word for it.

The system I built allowed our level designers to just add a new spawn point and the amount of rats to spawn at each point for each wave. A single spawn point can even mix and match different types of rats.

Sound engine rework

To begin to explain this I will first need to explain the state of the sound engine in our previous project.

We used a wrapper for the FMOD API made by the school in a projects 4 and 5. That was fine for basic 2D sound. In Spite: Wrath of Valkyria we used mainly 3D sounds and the wrapper we had was broken. That led me to start reworking large chunks of it to add functionality. On top of having to redo a lot of work we also had an external person, Albin Wrede, in charge of all of our sounds so we just expected everything to work out. Albin was amazing at using a lot of the built in features from FMOD that we sadly did not have support for and I rushed to throw things together.

That resulted in a few odd quirks such as having all sound event paths as defines. 150 lines of random defines just to be able to access all sounds. It was not pretty but it worked well enough.

So first up I made a system to loop through the sound bank on engine start and register all events automatically. It also checks if the sounds are 3D sounds or regular non-spatial sounds.

Then I made 2 new components where sounds can be added to a game object through a drop down menu. One component for regular sounds and one component for 3D sounds that updates their position when they move. This made it possible for anyone to change sounds played in the engine without having to recompile thing. 

Knowing that you might not always want a component to call a single sound I also updated all the old functions to request sounds straight from the sound engine.

Finally I added a few functions so that FMOD parameters, both global and local, can be changed in the game engine without needing to know the parameter names in advance. 

After all of those changes pretty much all of the features from the old wrapper had been replaced.

Grenade arc prediction

The grenade doesn't go straight so it was pretty hard to hit with because you never knew where it would land or if it would hit the ceiling and such.

Tossing around the physics formula I used to calculate needed start speed for the boomer rat, I got the opposite result of knowing where an object will be at any time based on initial speed which was a known factor for the grenade launcher.

I wish we could have solved this by just simulating a grenade throw with the physics engine but our engine currently lacks that support. Instead I had to use an ugly solution of doing a few raycasts to determine where the grenade will hit.

The picture here shows the current state of it as of writing this but this is not the planned final version. We want the path to pop a bit more and the collision point should be more clearly marked rather than just being slightly darker. 

bottom of page