Search will search the map by wandering until it finds the target. It can find the target by seeing or hearing the target.
How far ahead of the current position to look ahead for a wander
The amount that the agent rotates direction
The field of view angle of the agent (in degrees)
The distance that the agent can see
The LayerMask of the objects to ignore when performing the line of sight check
Should the search end if audio was heard?
How far away the unit can hear
The offset relative to the pivot position
The target offset relative to the pivot position
The LayerMask of the objects that we are searching for
The further away a sound source is the less likely the agent will be able to hear it. Set a threshold for the the minimum audibility level that the agent can hear
The object that is within sight