ABSTRACT

Crowd pathfinding and steering using flow field tiles is a technique that solves the computational problem of moving hundreds to thousands of individual agents across massive maps. This chapter demonstrates how to represent and analyze the pathable terrain to generate flow fields that can drive hundreds of units to a goal. Through the use of dynamic flow field tiles, a more modern steering pipeline can be achieved with features such as obstacle avoidance, flocking, dynamic formations, crowd behavior, and support for arbitrary physics forces, all without the heavy CPU burden of repeatedly rebuilding individual paths for each agent. The flow field holds all the primary directions and flags used by the agent’s steering pipeline for steering around hills and walls to flow toward the path goal. When agents steer with flow fields, there are some if-else conditions to look out for. For starters, if the agent doesn’t have a valid flow field, it should steer to the next portal position.