Tanoda
|
Public Attributes | |
ProximityEvent | OnProximity |
float | Period = .1f |
GameObject[] | TargetObjects |
string | TagName = "" |
bool | UseLayersNotList = false |
LayerMask | Layer |
float | OnDistance = .01f |
float | OffDistance = .015f |
bool | ShowGizmos = true |
![]() | |
UnityEvent | OnActivate |
UnityEvent | OnDeactivate |
Protected Member Functions | |
virtual void | OnValidate () |
Properties | |
GameObject | CurrentObject [get] |
![]() | |
bool | IsActive [get] |
Additional Inherited Members | |
![]() | |
virtual void | Activate () |
virtual void | Deactivate () |
![]() | |
Color | OnColor = Color.green |
Color | OffColor = Color.red |
Color | LimitColor = Color.blue |
Color | DirectionColor = Color.white |
Color | NormalColor = Color.gray |
Detects when the parent GameObject is within the specified distance of one of the target objects.
Definition at line 22 of file ProximityDetector.cs.
|
protectedvirtual |
Definition at line 101 of file ProximityDetector.cs.
LayerMask Leap.Unity.ProximityDetector.Layer |
Definition at line 62 of file ProximityDetector.cs.
float Leap.Unity.ProximityDetector.OffDistance = .015f |
The distance in meters between this game object and the target game object that will turn off the detector.
Definition at line 80 of file ProximityDetector.cs.
float Leap.Unity.ProximityDetector.OnDistance = .01f |
The distance in meters between this game object and the target game object that will pass the proximity check.
Definition at line 72 of file ProximityDetector.cs.
ProximityEvent Leap.Unity.ProximityDetector.OnProximity |
Dispatched when the proximity check succeeds. The ProximityEvent object provides a reference to the proximate GameObject.
Definition at line 29 of file ProximityDetector.cs.
float Leap.Unity.ProximityDetector.Period = .1f |
The interval at which to check palm direction.
Definition at line 37 of file ProximityDetector.cs.
bool Leap.Unity.ProximityDetector.ShowGizmos = true |
Whether to draw the detector's Gizmos for debugging. (Not every detector provides gizmos.)
Definition at line 96 of file ProximityDetector.cs.
string Leap.Unity.ProximityDetector.TagName = "" |
Include objects with the specified tag in the list of target objects. Objects are not added dynamically, however, so objects spawned with the tag will not be included.
Definition at line 56 of file ProximityDetector.cs.
GameObject [] Leap.Unity.ProximityDetector.TargetObjects |
The list of objects which can activate the detector by proximity.
Definition at line 46 of file ProximityDetector.cs.
bool Leap.Unity.ProximityDetector.UseLayersNotList = false |
Definition at line 59 of file ProximityDetector.cs.
|
get |
The object that is close to the activated detector.
If more than one target object is within the required distance, it is undefined which object will be current. Set to null when no targets are close enough.
Definition at line 90 of file ProximityDetector.cs.