My second year of University featured a AI module with an assignment to develop a pathfinding system for a tank. The goal of the assignment was to develop a pathfinding system that could navigate the tank through a provided map while collecting pickups as well as fighting against enemies.
The AI was completely programmed from scratch using C++, and was my first proper introduction to developing my own AI, and not creating one through established systems such as Unity’s provided AI systems. The assignment required the pathfinding to be created using a variation of A* which was developed by our lecturer at the time. Along with the pathfinding, a feeler system was used for obstacle avoidance which is represented by the circles ahead of the tank
This was without a doubt one of the most challenging assignments I had assigned at University. Being AI, it lead to a lot of frustrating moments where the AI would do exactly the opposite of what you intended for it to do, which in turn lead to a lot of sleepless nights trying to bug fix it. The obstacle avoidance was a big culprit that would often push the tank in the wrong direction towards the obstacle instead of avoiding it. Often this was due to my maths being a little off, with scaler values needing to be adjusted constantly to get the feeler to work just right. This made the whole thing a lot of trial and error but I got it working eventually. Fortunately all this did lead to a funny video that I made during the time.