Click or drag to resize

LaserPointer Class

The component responsible for the wand laser pointer.
Inheritance Hierarchy
SystemObject
  Object
    Component
      Behaviour
        MonoBehaviour
          RavingBots.MagicGestures.ControllerLaserPointer

Namespace:  RavingBots.MagicGestures.Controller
Assembly:  Assembly-CSharp (in Assembly-CSharp.dll) Version: 0.0.0.0
Syntax
C#
public class LaserPointer : MonoBehaviour

The LaserPointer type exposes the following members.

Constructors
  NameDescription
Public methodLaserPointer
Initializes a new instance of the LaserPointer class
Top
Properties
  NameDescription
Public propertyHoverElement
The UI element being pointed at, if any.
Public propertyHoverPosition
The position of the element being pointed at, if any.
Public propertyPressed
The current pressed state.
Public propertyPressElement
The UI element being pressed, if any.
Public propertyRay
Get the current ray for this pointer.
Top
Methods
  NameDescription
Private methodCastRay
Update the hover state based on the pointer ray.
Private methodGetOtherPointers
Get the other pointers from WandManager.
Private methodHoverStop
Clear the hover state.
Protected methodOnDisable
Clear the hover and pressed states when the pointer is disabled.
Private methodSetPressed
Update the pressed state.
Private methodStillHover
Check if the element still has any pointers pointing at it.
Private methodStillPress
Check if the element still has any pointers pressing it.
Protected methodUpdate
Update the hover state based on the pointer ray.
Top
Fields
  NameDescription
Private field_pressed
The current pressed state.
Top
Remarks
This component is responsible for updating the hover and press states of UI elements the user is pointing at with the motion controller. This is done by casting a ray from the tip of the wand in the direction it's facing.
See Also