RAIN.Sensors.ExpandingBoxSensor Class Reference

ExpandingBoxSensor is a BoxSensor that changes shape over time. ExpandingBoxSensor has a minimum size, maximum size, and expand rate (per axis) More...

Inheritance diagram for RAIN.Sensors.ExpandingBoxSensor:
RAIN.Sensors.BoxSensor RAIN.Sensors.RaycastSensor RAIN.Sensors.TriggerSensor RAIN.Sensors.Sensor

List of all members.

Public Member Functions

 ExpandingBoxSensor ()
 Default constructor.
override void Sense ()
 Sense instructs the Sensor to begin searching if it isn't already. Searching means expanding, not sensing. The Sensor will continue to detect, even at its initial or min size.
override void Reset ()
 Reset causes the sensor to stop searching and return to its initial size.
new void Update ()
 Update responds to the Unity Update event and causes the Sensor to update its size if it is searching.

Public Attributes

Vector3 expandRate = Vector3.zero
 Expand rate is a Vector3 describing the rate of size change of the box sensor.
Vector3 maxSize = Vector3.zero
 Max size is the maximum size the box sensor can reach in each axis.
Vector3 minSize = Vector3.zero
 Min size is the minimum size the box sensor can shrink to in each axis.
bool searching = false
 Searching indicates whether the Expanding Box Sensor is active and attempting to expand.

Protected Member Functions

override bool CreateEvidence (GameObject evidence)
 The expanding box sensor is used to search for some piece of evidence in the world. Once the evidence is found, the sensor will return to its initial size and stop expanding until it is reactivated. At its initial size, it will continue to collect evidence.

Detailed Description

ExpandingBoxSensor is a BoxSensor that changes shape over time. ExpandingBoxSensor has a minimum size, maximum size, and expand rate (per axis)


Constructor & Destructor Documentation

RAIN.Sensors.ExpandingBoxSensor.ExpandingBoxSensor ( )

Default constructor.


Member Function Documentation

override bool RAIN.Sensors.ExpandingBoxSensor.CreateEvidence ( GameObject  evidence) [protected, virtual]

The expanding box sensor is used to search for some piece of evidence in the world. Once the evidence is found, the sensor will return to its initial size and stop expanding until it is reactivated. At its initial size, it will continue to collect evidence.

Parameters:
evidenceThe GameObject detected for which evidence should be added to the Belief system.

Reimplemented from RAIN.Sensors.BoxSensor.

override void RAIN.Sensors.ExpandingBoxSensor.Reset ( ) [virtual]

Reset causes the sensor to stop searching and return to its initial size.

Reimplemented from RAIN.Sensors.Sensor.

override void RAIN.Sensors.ExpandingBoxSensor.Sense ( ) [virtual]

Sense instructs the Sensor to begin searching if it isn't already. Searching means expanding, not sensing. The Sensor will continue to detect, even at its initial or min size.

Reimplemented from RAIN.Sensors.Sensor.

new void RAIN.Sensors.ExpandingBoxSensor.Update ( )

Update responds to the Unity Update event and causes the Sensor to update its size if it is searching.

Reimplemented from RAIN.Sensors.RaycastSensor.


Member Data Documentation

Expand rate is a Vector3 describing the rate of size change of the box sensor.

Max size is the maximum size the box sensor can reach in each axis.

Min size is the minimum size the box sensor can shrink to in each axis.

Searching indicates whether the Expanding Box Sensor is active and attempting to expand.