This is a thesis I did for the university about the AI of the game agents of Cyber Dungeon Quest.
Including clojure code snippets and there is also a chapter about the movement and entity-component architecture.
This thesis presents a new method for pathfinding and cooperation in an existing realtime action video game. Multiple agents need to navigate around obstacles and avoid blocking each other at the same time. The method is a modified Potential-Field algorithm which, in order to avoid local optimas, flows into all directions and saves the distance at every step like a breadth-first-search. It is called the Wavefront-Expansion algorithm. Agents then look at their adjacent cells and move the other way round until they reach the center of the field. Cooperation is achieved by marking cells as occupied and avoiding cells that are occupied by other agents.