An Unreal Engine 4 game utilizing a custom AI solution as opposed to the engine's behaviour trees
10 members total, 3 of whom programmers;
Tools programmer, AI programmer, System engineer;
8 weeks in the end of 2nd year in BUAS;
Entirety of boids system, individual smaller tools for designers;
Crowd King is a game that was developed in the span of 8 weeks towards the end of my 2nd year in BUAS. The tech and tools were developed all within these 8 weeks using Unreal Engine 4, where as the game design and art work had been started prior to that, and had been in work for an extra 8 weeks.
The game is a standard agility course game, where besides making sure that the player character does not die, the player is also encouraged to take care of minions he collects throughout the level as a scoring system. The game can be found on itch.io.
I worked on the team as one of the three programmers, and primarily focused on developing the AI for the minions and tools for the designers, as well as smaller gameplay related tasks such as sounds and general bug fixes.
My most significant contribution to the project was a tool to "program" the AI of the minions, which as previously mentioned were to behave as boids. Now, Unreal Engine 4 by default has a behaviour tree system for that, but in our case I concluded that behaviour trees would result in a very clunky system. Because of this I opted to create a set of tools from scratch using what Unreal Engine has to offer.
The result was a tool which allowed designers to define how the individual minions interact with their surroundings using a list of rules. The system came along with a number of basic rules, such as the basic prerequisites for a boid system, as well as hazard avoidance and keeping close to the player character. However, if something more concrete was necessary, the designers were encouraged to create their own rules using blueprints.
One challenge that presented itself in the last weeks of the project's development cycle was the pathfinding for the boids, as I found that Unreal Engine's base path finding algorithm is not a good fit for the boids. This was most clearly shown by inconsistent FPS at specific parts of the levels, which would disappear as soon as the path finding was disabled.
Developing a custom solution to the path finding was definitely an option, but because the development of the game's tech started so late, it was deemed better to focus on polishing the game than develop the pathfinding.
The whole boids system has been made to work without utilizing the built-in behaviour tree feature of Unreal. This was done because I deemed the behaviour trees to be more-so limiting to the tool than helpful, based on previous experiences working with behaviour trees
While it would definitely be possible to recreate the system using a behaviour tree, I believe that the likelyhood of the tool quickly moving away from the tree and into custom code and architecture is very high. From my previous experience, the behaviour trees are meant as a way of evaluating singlular tasks at a time, while the boids needed to evaluate several tasks at all times to achieve the flocking.
Another tool that I worked on for the game was to allow the designers to more easily control the difficulty induced by the slugs shown in the trailer, by defining exactly how long it would take the the projectile to travel at certain distances instead of having to rely on setting the projectile speed and leaving it to physics. Because this made the projectile look unnatural, I added for them the ability to also define the exact trajectory the projectiles would take using the float curve tool that is provided with Unreal Engine 4.