Christopher Dragert

Ph.D. Candidate, M.Sc.


Overview

Originally a software engineer, my work started with the observation that software engineering techniques are underutilized in typical game development. In the rush to make release dates, good development practices are too often ignored. As a researcher, I have the opportunity to take a deep, in-depth look at how software engineering practices can be applied to game development. Specifically, I looked at game AI and set about applying software engineering practices to the development of game AI.


Statechart-based Game AI

Master Chief

AI in games is an interesting software engineering challenge. Unlike graphics, there is no texture-mapped triangle, no generally accepted representation. Techniques such as code generation, dynamic verification, and modular reuse are underutilized. My research explored a layered statechart-based AI approach. Fundamentally modular with a low representational complexity, statecharts are an excellent candidate for game AI.

To prove that layered Statecharts are up to the challenge posed by AAA games, we crafted a large-scale AI similar to the AI from the Halo series of FPS action games. We demonstrated successfully that the layered Statechart approach increases modularity and reusability, manages complexity, and does not sacrifice performance.

Paper Describing the Project

The Statecharts Comprising the AI


Mammoth

Mammoth Logo

Mammoth is a massively-multiplayer online game, developed as a research framework. It has been used to evaluate new approaches to pathfinding, load-balancing, along with extensive work on the replication engine to share in-game updates. With a code base exceeding 140K lines of code, it provides a complex and valuable test bed for high level research and development. Information can be found at the Mammoth home page.

My primary work in Mammoth was to build an AI engine. This included adding support for Statechart-based AI, supporting external definition and loading of AIs, along with integration of the Apache Commons SCXML statechart execution environment.

Notable amongst many minor modifications to Mammoth, I have also reworked the action execution environment. This created a formal interface to modify the game state, clarifying game actions, eliminating some spaghetti code, and allowing for proper exception handling. In addition, I worked with several artists and customized the content creation pipeline to build new maps and levels for the game.

The following video showcases some of my work on modular AI and AI variation within Mammoth:



Scythe AI

To enable game AI developers to perform modular reuse of NPC AI, I authored the tool Scythe AI. Built on a Statechart formalism that generalizes FSM and HFSM structures, it acts as middleware to reuse modules of previously developed AI. By allowing reuse of AI behaviours, developers are freed from reimplementing basic AI logic for each new NPC, making Scythe AI a valuable part of the game developer's toolkit.

The Scythe AI project page


Hybrid Force-Based Pathfinding

Force-based pathfinding is known as being a finicky approach, and difficult to use effectively. By integrating A*, I created a hybrid that avoids the local-maxima problem while preserving the fluid motion of force-based approaches. Check it out here:

Force-based Pathfinding Demo


Physically-Based Animations

With a background in physics, I took on some physically based animations. The cloth animations are modelled as a mesh of particles connected by springs. To advance each frame, we solve the differential equation using a damped first-order numerical method.

Next, I got to experiment with a Vicon motion capture rig (that's me in the video!). I explored Motion capture reuse, smoothly blending together like frames. As well, this formed the basis for some inverse kinematics. Finally, we combine both the motion capture and the particle simulation, which required complex collision detection and dampening for the particle system.