Unity pedestrian system: a crowd of AI pedestrians crossing a city street on a zebra crossing at a green pedestrian light

Mobile Pedestrian System — Unity pedestrian AI that knows about traffic

Root motion on any humanoid rig. No NavMesh. Complete C# source.

Mobile Pedestrian System fills your streets with people who walk the pavements, avoid each other and the scenery, wait at the kerb, and cross when the light says they can. It is a Unity pedestrian system built for cities rather than for stadium crowds — and it runs on phones.

It comes from the same workbench as Mobile Traffic System, which was nominated for Best Development Tool at the Unity Awards 2021, and the two are designed to share a street.

Pedestrians that know the road is dangerous

Most pedestrian and crowd assets move people from A to B. The interesting problem in a city is the twenty centimetres where the pavement stops.

This system handles crossings as a first-class thing. Pedestrians wait at the kerb, read the same traffic light the cars are reading, and step out when it changes — through an independent crossing component, so the crossing logic can be driven by Mobile Traffic System or wired to your own vehicle setup. Unsignalled crossings are supported too, for side streets and zebra crossings without lights.

The result is a street that reads as a street: cars stopping, people waiting, both moving again together, with nothing hand-scripted.

And pedestrians that can be hit

Drive into someone and they go down, then get back up. The knockdown and recovery behaviour works by default, with the animations included in the package — nothing to script. For a driving game it is the difference between pedestrians as scenery and pedestrians the player actually has to avoid.

How the pedestrian AI works

  • A waypoint grid, not a NavMesh. Pedestrians wander a grid you lay out over the walkable areas. Nothing to bake, no agent budget to exhaust, and the grid scales to any scene size because it is generated rather than hand-placed edge by edge.
  • Root motion, on your own characters. Movement is driven by Apply Root Motion from the character’s Animator, so any humanoid rig and any humanoid animation set works — including the ones you already bought. No bespoke controller to fight, and none of the sliding-feet problem that comes from moving a transform underneath an animation.
  • Obstacle avoidance, static and dynamic. People walk around benches and around each other.
  • Pooling and reuse. Pedestrians are recycled around the player rather than instantiated across the map, so a busy pavement near the camera costs far less than the size of your city suggests.
  • Events, delegates and an API. Subscribe to waypoint events, replace any behaviour with your own through delegates, or drive individual pedestrians directly.

What the pedestrians do

Movement and animation

  • Root-motion movement using the character’s own Animator
  • Any humanoid character and any humanoid animation set
  • Grid-based waypoint pathfinding that scales to any scene size
  • Static and dynamic obstacle avoidance

Streets and crossings

  • Crossings at traffic lights, synchronised with the vehicles using the same lights
  • Crossings without traffic lights, for side streets and unsignalled zebra crossings
  • An independent crossing component, so crossings can be driven by the traffic system or by your own vehicles
  • Priority waypoints for controlling where people prefer to walk
  • Pedestrian types with per-area access restrictions — keep civilians out of the docks, staff inside the depot

Behaviour and control

  • Pedestrians that follow a path you define — give a specific character a route instead of letting them wander, for a scripted walk, a patrol, or an NPC who needs to be somewhere
  • Custom waypoint events to trigger game logic at specific points
  • Delegates for replacing built-in behaviour with your own
  • Event subscription across the whole system
  • Custom editor tools for laying out and editing the grid
  • Complete documented C# source — nothing ships as a DLL

Package Content

All that you see in the demo is included inside the package:

  • 1 production-ready Pedestrian thanks to SICS Games.
  • Animations from the Adam project made by Unity: Die, Idle, Revive, Run, Walk.
  • 1 mobile production-ready car with 3 LODs and changeable colors, thanks to PolyNinja
  • 9 road tiles that can be assembled in any way to create complex roads.
  • 20 simple city buildings to populate your environment.
  • 1 demo scene that assembles all the above elements into the playable scene from the demo.

How to add pedestrians to a Unity scene

About fifteen minutes the first time. The documentation covers each step properly; this is the shape of it.

1. Import and run the demo

Import into a Unity 2021.3 LTS or newer project. A complete demo scene is included, so you can press Play and watch a working pedestrian system before touching your own scene.

2. Generate the walkable grid

Mark the pavements and open areas people should use and let the editor tool build the waypoint grid over them. Unlike a lane network, this is a grid because pedestrians wander rather than commute.

3. Place the crossings

Add crossing points where the pavement meets the road, and connect them to a traffic light if there is one. If you are also running Mobile Traffic System, they share the same lights automatically.

4. Add your characters

Drop your own humanoid prefabs into the pooling list with their Animators set to Apply Root Motion. Any humanoid rig works, so you can use characters and animation sets you already own.

5. Tune density and pedestrian types

Set how many pedestrians should exist around the player, and use pedestrian types to restrict who can walk where. Press Play.

Video walkthroughs are on the tutorials page.

Built for mobile

Crowds are expensive for an obvious reason: every person is an animated skinned mesh. This system spends its budget where the player is looking — pedestrians are pooled and reused around the camera, so density near the player stays high while the total count stays low, and the per-agent work is Burst-compatible. It runs on any platform that supports the Burst compiler: Windows, macOS, Linux, Android and iOS.

Add traffic to the same street

Pedestrians are half of a living city. Mobile Traffic System supplies the other half — AI cars that overtake, obey the same traffic lights your pedestrians are reading, and run 300 of them on a phone. The two are independent packages that integrate directly.

If you want both, the Complete City Traffic & Pedestrian System bundles them for less than buying them separately, and includes an example scene with the two already working together.

Requirements

  • Unity 2021.3 LTS or newer
  • Any platform supporting the Burst compiler — Windows, macOS, Linux, Android, iOS
  • Complete documented C# source code included; nothing ships as a DLL
  • No third-party dependencies required

Frequently asked questions

Does it need NavMesh?

No. Pedestrians walk a waypoint grid you generate over the walkable areas. There is nothing to bake and no NavMesh agent limit — which also means none of the usual friction between root motion and a NavMesh agent.

Can I use my own characters?

Yes, and that is the point. Movement uses Apply Root Motion from the character’s own Animator, so any humanoid rig and any humanoid animation set works. Characters you already own will drop straight in.

Do pedestrians actually stop for cars?

Yes. Crossings are handled by an independent crossing component that reads traffic lights — the same lights the vehicles read when you are running the traffic system, or your own if you wire it up. Unsignalled crossings are supported as well.

What happens if the player hits a pedestrian?

They go down, and then they get back up. The knockdown and recovery behaviour works out of the box and the animations ship with the package, so you get it without writing anything — and the event system lets you hook your own logic to it for scoring, damage or a wanted level.

Does it work without the traffic system?

Yes. The two packages are completely independent. Pedestrians work in a scene with no cars in it at all, and you can add traffic later without touching the pedestrian setup.

Will it run on mobile?

Yes. Pedestrians are pooled and reused around the player, so density near the camera is what costs you rather than the size of the city, and the per-agent work is Burst-compatible.

How many pedestrians can it handle?

Density is a setting rather than a hard limit, and the real constraint is usually your character meshes and animations rather than the AI. Because of pooling, what matters is how many are visible at once, not how large your scene is. The PC demo is the fastest way to judge it.

Which render pipeline does it support?

Built-in, URP and HDRP. The AI is renderer-agnostic; only the demo materials are pipeline-specific.

Can I control where people are allowed to walk?

Yes — pedestrian types can be restricted to specific areas, and priority waypoints let you bias where people prefer to go. Custom waypoint events let you trigger your own logic at any point on the grid.

Can I make one pedestrian walk a specific route?

Yes. Alongside the ambient wandering, you can give an individual pedestrian a path to follow — useful for a scripted walk, a patrol route, or an NPC who has to arrive somewhere at a particular moment.

Can I change how a pedestrian behaves?

Yes. Behaviour is exposed through delegates and events, and the complete commented C# source is included, so anything you cannot configure you can rewrite.

Is this a crowd simulation system?

Not in the stadium-and-evacuation sense. This is built for street-level city pedestrians — people using pavements, obeying crossings and sharing a road with traffic. If you need tens of thousands of GPU-instanced bodies in an arena, a dedicated crowd renderer is the better tool.

Tutorials

Install and Test

Integration Tutorial

Custom Behaviours

Documentation, demos and support

Read the documentation · Watch the tutorial series · Add AI traffic · Get both in one bundle

Support is handled by the person who wrote the code — full written docs, a video tutorial series, and a Discord where you can ask directly.

Get Mobile Pedestrian System on the Unity Asset Store

Want to get in touch?