Sight¶
Overview¶
Sight decides whether an agent notices a target in the first place: how far it can see, how wide an angle it watches, and whether a wall can block the view. In motion, a short-ranged or narrow-cone archetype lets the player walk past unnoticed or come in from behind, while a wide, all-around Sight makes an archetype impossible to sneak up on. Reach for it the moment stealth, ambush, or "did it see me" should mean anything for this archetype.
Lives on the Perception Profile, feeds target selection directly
Sight is a section of the archetype's Perception Profile asset. Unlike Following The Crowd and Searching, it does not need Approach & Press enabled to do its job: Sight also decides which targets this agent is even allowed to select, so it keeps working even for an archetype whose Behavior Profile has no steering that responds to losing contact.
The Simple and Advanced grouping below is this page's own, not the inspector's. The Perception Profile has no mode switch. Occlusion Detour Tolerance only appears once Occlusion is Navigation Path, and with Sight off or Range at 0 the section stops after Field Of View.
Parameter Reference¶
Simple Parameters¶
Start here: these four decide whether this archetype can be sneaked past
Enabled¶
This is the checkbox on the Sight section header, not a row inside it.
- Visible effect: Agents with a Perception Profile assigned notice nothing on their own and stay idle until something else tells them, such as an Alert Spread call or a scripted stimulus.
- Gameplay effect: The difference between an archetype that actively hunts and one that sits dormant until woken, useful for ambush spawns or sleeping guards.
- Increase when: Not applicable, it is a toggle.
- Decrease when: Not applicable, it is a toggle.
- Pitfalls: Turning this off does not turn the rest of perception off. Awareness and the recovery ladder still exist underneath; an agent with Sight off just never feeds them anything on its own.
- Technical effect: Skips the whole sense sample for this agent every step, so its detected mask stays empty and only a stimulus write, such as an alert call,
EmitStimulus, or a damage hook, can ever set what it perceives.
Range¶
- Visible effect: How close a target has to get before this archetype notices it exists, whatever it is facing.
- Gameplay effect: A short Range paired with the recovery ladder is what makes an archetype sneakable: get close enough and it reacts, hang back and it never does. A long Range reads as permanently alert.
- Increase when: Sentries, snipers, or anything that should react to a target across the whole arena.
- Decrease when: The player should be able to approach, flank, or slip past this archetype at moderate distance.
- Pitfalls: Range alone does not decide visibility. A huge Range with a narrow Field Of View or Occlusion turned on can still leave an archetype blind to a target standing right beside it, just outside the cone or around a corner.
- Technical effect: Any active target further than this from the agent, measured on the horizontal plane, is dropped before the facing or occlusion checks even run. The value cannot go below 0, and at 0 the agent sees nothing.
Field Of View¶
- Visible effect: A full circle notices a target in any direction. Narrower values only notice a target inside a cone centred on the way the agent is facing, so something approaching from behind goes unnoticed until it steps into that cone.
- Gameplay effect: A narrow cone is what makes flanking, backstabs, and approaching from behind actually work against this archetype. A full circle makes it unflankable.
- Increase when: This archetype should be impossible to sneak up on, such as an alert sensor or a swarm of insects with no real "behind."
- Decrease when: Flanking or approaching from behind should matter for this archetype.
- Pitfalls: The cone only gates spotting a target for the first time. An agent that is already chasing a target keeps it even if that target circles around behind, so narrowing this stops a target being noticed, but never makes a chasing agent lose one mid-pursuit. Losing one is entirely Range and Forget Time on Awareness.
- Technical effect: A full circle returns a facing test that always passes. A narrower cone computes the angle between the agent's forward direction and the direction to the target and rejects anything outside it, but only for a target the agent does not already hold a bit for. The width is clamped between 1 and 360 degrees.
Occlusion¶
- Visible effect: With None (sees through walls), a target is noticed the moment it is inside Range and the cone, wall or no wall. With Navigation Path (no physics), a target behind solid geometry stays unnoticed even at close range, until the agent has a walkable line to it.
- Gameplay effect: None is the cheap "everyone always knows where the player is" setting. Navigation Path is what makes rooms, buildings and corners actually matter, letting a crowd hunt room to room instead of tracking a target through solid walls.
- Increase when: Not a scale. Pick None or Navigation Path.
- Decrease when: Same.
- Pitfalls: Navigation Path needs a Swarm Manager running a baked Surface Flow Field at Smooth or Eikonal quality. Without one, the test cannot tell where a wall is, so it answers "not blocked" for everything and Occlusion does nothing at all, however tight Range or Field Of View is set. Nothing warns you at runtime, but the Sight section of the inspector shows a warning with a fix button when the Swarm Manager in the open scene is missing the field.
- Technical effect: Compares the baked walking cost from the agent's cell to the target against the straight-line distance between them, using the field's integration data rather than a physics raycast. A walk far longer than the straight line means something solid is in the way.
Advanced Parameters¶
Power-user knob: leave at defaults unless you have a reason
Occlusion Detour Tolerance¶
- Visible effect: How much longer the walkable route to a target is allowed to be than the straight-line distance before Occlusion still calls it seen. Raise it and sight reads through a doorway or a slight jog in a corridor; lower it and open ground next to a wall starts reading as blocked.
- Gameplay effect: The slack between "has to walk slightly around something" and "genuinely cannot see this." Too tight and agents go blind standing next to open doorways; too loose and they effectively see through walls Occlusion was meant to respect.
- Increase when: Sight keeps reading as blocked at doorways, corners, or grid-aligned routes that are honestly still within view.
- Decrease when: Agents are noticing targets through walls they clearly should not, across a short detour.
- Pitfalls: Only matters when Occlusion is set to Navigation Path. With None it is ignored entirely, and with no baked field it never gets the chance to run in the first place.
- Technical effect: Scales the straight-line distance to the target into an allowed walking cost, plus a small fixed buffer for baking and position noise. The agent's baked route cost has to exceed that scaled allowance before Occlusion calls the target blocked. The tolerance never goes below 1.
Seeing the cone before you press Play¶
The Sight section draws the settings above it as a picture: a top-down view of one agent facing up the page, with the lit wedge showing where it can notice a target and the dim area behind it showing where it cannot. The rings are labelled in units, so Range reads as a distance you can hold against the size of a room rather than as a number on its own. Drag inside the circle to set the angle instead of typing it.
The wedge is the part a picture answers better than a number, because a cone decides only whether a target gets noticed. The circle around it is the whole of Range, which is what the agent keeps a target inside once it has one.
In Play mode the same two shapes are drawn on the agents themselves. Open Tools > Massive Swarm System > Swarm Debug, find the Scene Gizmos foldout and turn on Sight Cones. Colour there says what the agent currently has: green while it can see a target, amber while it knows about one it has lost, grey while it has nothing.
What Field Of View and Occlusion add up to¶
Those two are separate knobs, and between them they pick one of four ways an archetype can see. The inspector works the combination out and prints the matching line at the top of the Sight section, so nobody has to remember that 360 degrees means no cone at all. A new profile starts as the first row: Sight on, Range 25 units, Field Of View 360, Occlusion None, and a tolerance of 1.3.
| Field Of View | Occlusion | How the archetype sees |
|---|---|---|
| 360 | None | Distance only. Anything inside Range is noticed, whatever the agent faces and whatever stands between the two. The cheapest of the four. |
| Under 360 | None | Distance and facing. A target has to be inside Range and inside the cone, and a wall between them changes nothing. |
| 360 | Navigation Path | Distance and walls. Anything inside Range that the agent has a way to reach is noticed, whatever direction it faces. A route check per candidate, while the agent is still looking. |
| Under 360 | Navigation Path | Distance, facing and walls. The full set, and the most expensive: a route check per candidate that clears the cone, while the agent is still looking. |
Distance only is where a horde in the open belongs. It comes close to what an archetype with no Perception Profile does for free, but the two are not the same thing: Range still applies, so a target far enough away goes unnoticed, and Awareness still decides how quickly the agent commits once it does notice one. Pick it when an archetype should still be allowed to know where the player is through a wall, and you want the rest of the profile anyway.
Both Navigation Path rows cost less than "a route check per candidate" suggests, for two reasons worth knowing before you read a profiler.
An agent with nothing near it never reaches the test. Each step the manager puts one box around every active target and measures every agent against it, so an archetype hunting a player across a wide level pays almost nothing while the crowd is spread out. Range decides who gets past that box.
An agent that has already locked onto a target stops re-asking whether the wall is still there on every step. It keeps testing Range every step, so a target walking out of Range is lost the moment it leaves, and it re-runs the route check only every few steps.
The second one buys a short delay. A target ducking behind a corner is lost a few physics steps later, a fraction of a second at a normal Fixed Timestep. On those spaced steps the agent is also a few steps slower to notice a second target while it holds the first. An agent that has not noticed anything yet is never spaced out, so two agents standing together still notice the same target on the same step.
The spacing turns itself off in two cases. A Forget Time shorter than 32 fixed steps (about 1 second at 30 FixedUpdates per second) is sampled every step, since a delay that size would eat a visible share of how long the agent remembers. A profile with a full circle Field Of View and Occlusion on None has nothing to defer, so it is sampled every step too.
When Navigation Path cannot answer¶
Navigation Path falls back to seeing, never to blindness, whenever it cannot measure the route. That covers a missing or Cardinal Surface Flow Field, an agent standing outside the baked area, and an agent on a cell with no walkable route even one step away. A crowd that ignores a player standing in front of it looks broken, while one that sees a little too much does not.
It also cannot model a sight line that nothing can walk, such as a target across a gap or one on a floor above. The inspector says so under the Occlusion row.
A closed door with a high Route Cost hides what is behind it from agents whose Sight uses Navigation Path, because the walk through it costs far more than the straight line. See Doors and Barricades for how to set that cost.
Practical Usage Guidance¶
Use a tight Range and Field Of View with Navigation Path on for stealth-leaning games, guard patrols, or any archetype that should be genuinely sneakable. Pair it with a deliberate Awareness Acquire Time for a visible "it noticed me" beat, and with Alert Spread if one guard spotting the player should wake the room.
Skip Sight tuning entirely, and skip the Perception Profile altogether, for a default open-arena horde where every enemy should always know where the player is from the moment it spawns. A wide Range, full circle Field Of View and Occlusion off just reproduces that behavior at the cost of running the sense test every step.
Gameplay Interpretation¶
Range and Field Of View together decide how easy this archetype is to avoid: short and narrow reads as an archetype the player can outmanoeuvre, wide and full-circle reads as one that is always watching. Occlusion is what makes indoor and outdoor archetypes feel different from each other at the same Range: None behind a wall is exactly as alert as None in the open, while Navigation Path genuinely loses track of a target that ducks around a corner.
Quickstart: tune in this order
- Tick the checkbox on the Sight header and set
Rangeto how far this archetype should notice a target in the open. - Narrow
Field Of Viewonly if flanking or backstabs should matter for this archetype. - Turn
Occlusionto Navigation Path once the level has walls worth respecting, and confirm a Surface Flow Field is baked at Smooth or Eikonal quality. - Adjust
Occlusion Detour Toleranceonly if doorways or corridor jogs read as falsely blocked.