Show / Hide Table of Contents

    Class SteamVR_Action_Vibration_Source

    Inheritance
    System.Object
    SteamVR_Action_Source
    SteamVR_Action_Out_Source
    SteamVR_Action_Vibration_Source
    Implements
    ISteamVR_Action_Out_Source
    ISteamVR_Action_Source
    Inherited Members
    SteamVR_Action_Source.fullPath
    SteamVR_Action_Source.handle
    SteamVR_Action_Source.actionSet
    SteamVR_Action_Source.direction
    SteamVR_Action_Source.inputSource
    SteamVR_Action_Source.setActive
    SteamVR_Action_Source.inputSourceHandle
    SteamVR_Action_Source.action
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ToString()
    System.Object.ReferenceEquals(System.Object, System.Object)
    Namespace: Valve.VR
    Assembly: Assembly-CSharp.dll
    Syntax
    public class SteamVR_Action_Vibration_Source : SteamVR_Action_Out_Source, ISteamVR_Action_Out_Source, ISteamVR_Action_Source

    Fields

    vibrationAction

    Declaration
    protected SteamVR_Action_Vibration vibrationAction
    Field Value
    Type Description
    SteamVR_Action_Vibration

    Properties

    active

    Returns true if this action is bound and the ActionSet is active

    Declaration
    public override bool active { get; }
    Property Value
    Type Description
    System.Boolean
    Overrides
    SteamVR_Action_Source.active

    activeBinding

    Returns true if the action is bound

    Declaration
    public override bool activeBinding { get; }
    Property Value
    Type Description
    System.Boolean
    Overrides
    SteamVR_Action_Source.activeBinding

    lastActive

    Returns true if the action was bound and the ActionSet was active during the previous update

    Declaration
    public override bool lastActive { get; protected set; }
    Property Value
    Type Description
    System.Boolean
    Overrides
    SteamVR_Action_Source.lastActive

    lastActiveBinding

    Returns true if the action was bound during the previous update

    Declaration
    public override bool lastActiveBinding { get; }
    Property Value
    Type Description
    System.Boolean
    Overrides
    SteamVR_Action_Source.lastActiveBinding

    timeLastExecuted

    The last time the execute method was called on this action

    Declaration
    public float timeLastExecuted { get; protected set; }
    Property Value
    Type Description
    System.Single

    Methods

    Execute(Single, Single, Single, Single)

    Trigger the haptics at a certain time for a certain length

    Declaration
    public void Execute(float secondsFromNow, float durationSeconds, float frequency, float amplitude)
    Parameters
    Type Name Description
    System.Single secondsFromNow

    How long from the current time to execute the action (in seconds - can be 0)

    System.Single durationSeconds

    How long the haptic action should last (in seconds)

    System.Single frequency

    How often the haptic motor should bounce (0 - 320 in hz. The lower end being more useful)

    System.Single amplitude

    How intense the haptic action should be (0 - 1)

    Initialize()

    [Should not be called by user code] Initializes the handle for the inputSource, and any other related SteamVR data.

    Declaration
    public override void Initialize()
    Overrides
    SteamVR_Action_Source.Initialize()

    Preinitialize(SteamVR_Action, SteamVR_Input_Sources)

    Declaration
    public override void Preinitialize(SteamVR_Action wrappingAction, SteamVR_Input_Sources forInputSource)
    Parameters
    Type Name Description
    SteamVR_Action wrappingAction
    SteamVR_Input_Sources forInputSource
    Overrides
    SteamVR_Action_Source.Preinitialize(SteamVR_Action, SteamVR_Input_Sources)

    Events

    onActiveBindingChange

    Event fires when the active state of the binding changes

    Declaration
    public event SteamVR_Action_Vibration.ActiveChangeHandler onActiveBindingChange
    Event Type
    Type Description
    SteamVR_Action_Vibration.ActiveChangeHandler

    onActiveChange

    Event fires when the active state (ActionSet active and binding active) changes

    Declaration
    public event SteamVR_Action_Vibration.ActiveChangeHandler onActiveChange
    Event Type
    Type Description
    SteamVR_Action_Vibration.ActiveChangeHandler

    onExecute

    Event fires whenever this action is executed

    Declaration
    public event SteamVR_Action_Vibration.ExecuteHandler onExecute
    Event Type
    Type Description
    SteamVR_Action_Vibration.ExecuteHandler

    Implements

    ISteamVR_Action_Out_Source
    ISteamVR_Action_Source
    In This Article
    • Fields
      • vibrationAction
    • Properties
      • active
      • activeBinding
      • lastActive
      • lastActiveBinding
      • timeLastExecuted
    • Methods
      • Execute(Single, Single, Single, Single)
      • Initialize()
      • Preinitialize(SteamVR_Action, SteamVR_Input_Sources)
    • Events
      • onActiveBindingChange
      • onActiveChange
      • onExecute
    • Implements
    Back to top Copyright (c) Valve Corporation, All rights reserved.