Skip to content

Shape Spawners

Shape spawners decide where an agent can appear. Two are included.

Swarm Rect Spawner

Spawns agents in a rectangular area. Use it for waves entering from an edge or side of the level.

Add via right-click in Hierarchy → Massive Swarm System → Spawners → Rect Spawner.

Swarm Rect Spawner inspector showing the Spawn Profile, Auto Spawn, Spawn Origin, and Spawn Shape sections

The Rect Spawner inspector. Spawn Profile picks the archetype, Auto Spawn controls whether the spawner fills itself on Start, and Spawn Shape sets the rectangle (Rect Extents + Spawn Plane). Press Edit Shape to drag the rectangle handles in the Scene view.

Scene view of a selected Rect Spawner showing its cyan rectangle gizmo marking the spawn area on the ground

With the spawner selected, the cyan rectangle marks the spawn area set by Spawn Shape (Rect Extents and Spawn Plane). Use Edit Shape in the inspector to drag its corner handles. Agents spawn at random points inside this rectangle.

Swarm Ring Spawner

Spawns agents in a ring around a center point. Use it for ambushes or encirclement setups.

Add via right-click in Hierarchy → Massive Swarm System → Spawners → Ring Spawner.

Key fields

Field What it does
Spawn Profile The SwarmAgentArchetype used by this spawner when it spawns directly (no director) or when the director's composition list is empty.
Auto Spawn When on, this spawner spawns the auto-spawn count itself on Start or OnEnable. Turn this off when a director drives the spawner.
Auto Spawn Count How many agents Auto Spawn requests. A newly added spawner defaults to 32 agents.
Spawn Origin / Plane / Shape Where the spawn area sits and how big it is.
Off-Screen Spawning Optional rule that resamples positions until they sit outside the visible camera area.

Warning

If a director references a shape spawner and that spawner has Auto Spawn enabled, both will spawn agents on Start. The spawner inspector flags this. Disable Auto Spawn on the spawner to make the director the sole owner.

Common patterns

Pattern How
Single-burst encounter One shape spawner, Auto Spawn on, Auto Spawn Count set. No director needed.
Waves entering from one edge Rect Spawner aligned to a level edge, driven by a director in Continuous mode.
Off-screen ambush around the player Ring Spawner parented to the player, Off-Screen Spawning on, driven by a director or triggered from script.