Sensors Receiver Component
The Sensors Receiver component is responsible for reacting in a certain way when the sensors cast from the Sensors component are detected.
It works together with the Sensors component, and is required for the Sensors system to work.

Configuring the callback type

The callback type determines what happens, when the sensors are detected.
By default, the callback type is set to Disable Renderer, which automatically disables the renderer when there are no sensors detected, and only enables it when it is being detected by the sensors.
Assigning custom callback type
If you want to have custom behavior instead of the default one, which is disabling the renderer, you can set the callback type to Custom. By switching to the custom option, you can subscribe to two UnityEvent properties: OnSensorsReceived and OnSensorsLost.
OnSensorsReceived event is fired once when the sensors are first detected. OnSensorsLost event is fired once when the sensors are no longer being detected.

Changing the check interval

By default, the receiver checks every second for any sensors being present at the moment. To optimize the performance, you can change the check interval to your needs.
Keep in mind that more frequent checks are more computationally heavy.
Configuring the Sensors ID

The Sensors Id property can be configured to detect sensors fired only from a certain Sensors component that match by the ID. By default, this property is set to 0.
Last updated