Education Projects

Final Year ProjectImage Not Found

An Agent-Based Model Simulation which uses a genetic algorithm to test how changing the traits and environmental factors affect the evolution of AI agents.

The simulation placed 40 agents against 40 enemies in a small "arena" for 60 seconds, i was then able to select a range of additional traits and evionmental factors which would affect the agents.

My project focused on trying to find a pattern to how genetic algorithms evolve the agents and how genetic algorithms could be used more often within the gaming industry.

Using a fitness formula of (time survived + number of attacks made), which favored surviving over dealing damage. The agents were found to perform better when given traits which would help them group together rather than try to kill the enemies first, in terms of both average fitness score and average survival rate.

After testing i found the best genetic algorithm specifications were:

  • Tournament selection
  • Simple elitism of 1 agent
  • 1 point crossover
  • Crossover rate of 100%
  • Mutation rate of 20%

Throughout my project i came to the conclusion that genetic algorithms could be used much more often wihtin the games industry both at within games to evolve the AI and as a method to properly balance the stats of enemies within video games before release.

Group Engine/Game DevelopmentImage Not Found

In a team of originally 8 members. We planned, designed, and programmed a self-contained rogue-lite engine. Then used the engine to make a small game.

Within the team i took upon the role of programming the AI, weapon, and projectile classes for both the engine and game

We decided to code basic AI enemies into the engine as all rogue-lite games have some form of enemies; meaning even a developer with no AI experience could make enemies using the engine.

The engine was built using a component system and so all the AI, weapons, and projectiles are used by adding the relevant component to an object. Furthermore the majority of the methods which run the functionality and gameplay of my classes can be overriden giving future developers full control of the AI behaviour.

I also programmed the resource manager which handles all audio files, texture files, and object pooling.

The engine included a range of features needed for a complete engine, such as:

  • Component system
  • Collision manager
  • Camera manager
  • Input handling
  • Resource manager
  • Scene manager
  • Physics manager
  • Audio manager
  • Object manager
  • UI manager
  • Sprite rendering & animation

Tower DefenseImage Not Found

Single Problem solution found using a genetic algorithm

Unlike the "Flappy Bird" project, this project required the genetic algorithm to find a solution to a single problem.

The aim was to find a solution that could achieve a score of atleast 200 consistently, as seen in the video.

After running a range of tests the best solution was produced when using the genetic algorithm specifications:

  • 100 Agents
  • 40 generations
  • 12 tower types and positions per agent chromosome
  • Ranked roulette selection
  • Single point crossover
  • Dynamic crossover/mutation rates
  • 2 values mutated per mutation

Evolutionary Flappy BirdImage Not Found

Training a neural network birds with a genetic algorithm, to find a multi-problem solution in C++.

Part of the final year AI module.

The aim of the project was to create a bird that could reach a score of 400. Using the provided framework I programmed a neural network which used a genetic algorithm to develop its weights and biases.

The neural network used:

  • 3 inputs
  • 1 output
  • 3 hidden layers
  • 6 nodes per hidden layer

The genetic algorithm used:

  • Tournament selection
  • 3 simple elitism agents
  • Odd/Even crossover
  • Crossover rate of 1
  • Mutation rate of 0.03

The highest score achieved was 1840 on the 468th genertion.

The first video shows the trained bird reaching 500 and the second video shows a small clip of randomly weighted birds being trained

Chess AlgorithmImage Not Found

Chess Algorithm using C++, as part of the final year AI module.

Given a basic framework which could be used to play chess, i added all the AI elements which make decisions using the mini-max algorithm.

The project involved using a variety of researched techniques to create an intelligent chess algorithm which could make decisions at run-time in a "Rapid" chess format. Some of the techniques used are:

  • Minimax
  • Alpha-Beta Pruning
  • Removing the minimax tree creation
  • Framework optimizations
  • Playbooks
  • Board Evaluation
    • Board position values
    • AI playing styles

Sorting the first depth of the minimax tree was also tested, however at the low depth the algorithm runs, there was no improvement.

The chess algorithm is able to run at a depth of 4 where almost all decisions can be made in under a minute.

Each node takes around 0.0007 seconds to evaluate using a Ryzen 7 2700x.

Flocking SimulationImage Not Found

Flocking Simulation using C++, as part of the final year AI module.

Taking the basic framework which rendered square objects i added the implemented the physics-based movement for the boids(blue) and predator(red).

The boids use the flocking methods (Seperation,Alignment, and Cohesion) created by Craig Reynolds to move around the scene. Various method weighting were used to create different behaviours.

Within this simulation the boids also gain a short speed boost when they see the shark using peripheral vision.

The predator does not use flocking methods, though it uses similar steering behaviours and the same method for finding nearby boids.

Low-Level Game ProgrammingImage Not Found

Final year low-level programming module, using C++ and the provided raytracer framework.

Using the framework which was able to use raytracing to render spheres.

I implemented a range of techniques to manage memory and improve processing time.

  • Threading
  • Animations
  • Heap Management
  • Low-level Debugging
  • Visual Studio Profiling
  • Porting to Linux - VMWare Ubuntu

My additions took the framework from a completion time of over 100 seconds to 8-10 seconds (Windows). 7-9 seconds (Linux).

At 640x480 resolution, using a Ryzen 7 2700x.

Tank AIImage Not Found

Second year artificial intelligence project to create an AI tank using C++ and the SDL library.

The project included taking a variety of AI techniques to create an efficient self-contained tank AI.

Such as:

  • FSM & FuSM decision making
  • DRS pathfinding
  • Steering behaviours
    • Seek
    • Arrive
    • Pursuit
    • Obstacle avoidance
    • Etc

Physics-EngineImage Not Found

Second year project to create a physics engine using Directx 11 & C++.

Using a DirectX 11 graphics engine as a framework, I added a range complex physics techniques such as:

  • Particle system (fire, snow, rain)
  • Partial seperating axis theorem
  • AABB collision
  • Bounding box collision
  • Sphere collision
  • Collision resolution
  • Rigidbody physics
  • OctTree for game objects

Many of the techniques/features listed can be seen in the videos of the slideshow.

Image Not Found

Graphics EngineImage Not Found

Second year project, where DirectX 11 and C++ were used to create a Graphics Engine.

The project included a range of techniques such as:

  • Phong shader
  • Blur shader
  • Directional lighting
  • .OBJ loaded 3D/2D models
  • Texturing
  • Transparency
  • Culling
  • Skybox
  • Render-to-texture
  • Object movement/rotation
  • Billboarding
  • Keyboard/mouse input

Many of these techniques can be seen in the video.

Concurrent Network BattleshipsImage Not Found

Second year project to create a game which used a client-server architecture, programmed in C#.

For the module I created the "Battleships" game using windows forms, which clients could play against each other on the server.

The project used a range of techniques to allow multiple concurrent games to run efficiently, such as:

  • packet handling
  • TCP
  • UDP
  • Windows forms/UI
  • 2D animation
  • threading
  • thread-safe techniques
  • concurrent dictionaries

The clients were able to join the game queue, communicate publicly/privately, and challenge each other

Image Not Found
Image Not Found
Image Not Found

Mario & GravityGuy Mini GamesImage Not Found

First year university project. Created using C++ and the SDL library.

For the module I produced two small mini games which parodied "Mario" and "GravityGuy".

The games included many of the basic necessities for a video game such as simple AI, Collision detection/response, 2D animation.

On top of the basic functionality the "GravityGuy" game also used modular levels from text files and gave a multiplayer option.