top of page
plain paper image, subtle texture low quality paper white_edited.jpg

C++

This page showcases some of the C++ projects I've worked on during my time at university, focusing on project structure, memory management and application development in the windows console through the use of libraries such as OpenGL, OpenAL and SDL2.

​

plain paper image, subtle texture low quality paper white_edited.jpg

Memory Management...

When I first began working in C++ I was tasked with developing a basic Windows console game similar to space invaders. On top of that I had to improve on the code and implement another game and/or multiple levels in the process.

​

To achieve this, I introduced the use of raw and smart pointers to allow data sharing among player characters, aliens, and projectiles. This allowed for the efficient repurposing of mechanics from the first level of space invaders to the 2nd, 3rd and even the pong game.

​

For instance, paddle movement, derived from the ship's mechanics, was adapted to enable vertical motion. Additionally, I repurposed the floor and ceiling colliders from Space Invaders to track points in Pong and even adapted the projectiles movement for its alternative use as the pong ball.

​

By using pointers to repurpose existing mechanics, I not only streamlined development but also optimized memory usage throughout the program.

​

plain paper image, subtle texture low quality paper white_edited.jpg

OpenGL...

when I first began using OpenGL I undertook a project adhering to strict specifications, outlining the creation of a game featuring three models, textured and skinned for visual depth. A single camera and collision detection were paramount, along with imported shaders for visual aesthetics and OpenAL for audio integration.

​

In tackling this challenge, I focused on optimizing the code structure through object management. This approach allowed me to essentially make a pre-set, from which I could create as many objects as I liked, along with having easier access to object movement/ rotation, model swapping, texturing and shader binding.

​

I also created an automatic sphere collider file which would generate a collider automatically for each object, the colliders included dynamic sizing which involved measuring the size of the object it was attached to and increasing or decreasing the collider size to fit that specific object. The colliders also shared the same movement and rotation as the objects in order to maintain correct orientation.

​

After establishing the three objects and their dynamic colliders, I shifted focus to implementing triggered and timed events. This involved setting a timer for the bomb's drop and enhancing collision events, such as the bomb colliding with the house. Upon collision, the background colour changed, and both the bomb and house were moved off-screen, triggering the rendering deactivation of these objects. Concurrently, the explosion model, initially off-screen and not rendered, was moved onto the screen and rendered with a new shader.

plain paper image, subtle texture low quality paper white_edited.jpg

SDL2...

LOGO-escaperoom small_edited.jpg

[More Details To Come!]

bottom of page