{"_id":"594949e72be16d0026ec0513","category":{"_id":"594949e62be16d0026ec04e1","version":"594949e52be16d0026ec04cd","project":"571fa55ca0acd42000af9545","__v":0,"sync":{"url":"","isSync":false},"reference":false,"createdAt":"2017-02-25T10:45:46.612Z","from_sync":false,"order":19,"slug":"daydream-sdk","title":"Daydream SDK"},"user":"571fa519db52d01700f5cf3d","project":"571fa55ca0acd42000af9545","version":{"_id":"594949e52be16d0026ec04cd","project":"571fa55ca0acd42000af9545","__v":2,"createdAt":"2017-06-20T16:14:29.816Z","releaseDate":"2017-06-20T16:14:29.816Z","categories":["594949e62be16d0026ec04ce","594949e62be16d0026ec04cf","594949e62be16d0026ec04d0","594949e62be16d0026ec04d1","594949e62be16d0026ec04d2","594949e62be16d0026ec04d3","594949e62be16d0026ec04d4","594949e62be16d0026ec04d5","594949e62be16d0026ec04d6","594949e62be16d0026ec04d7","594949e62be16d0026ec04d8","594949e62be16d0026ec04d9","594949e62be16d0026ec04da","594949e62be16d0026ec04db","594949e62be16d0026ec04dc","594949e62be16d0026ec04dd","594949e62be16d0026ec04de","594949e62be16d0026ec04df","594949e62be16d0026ec04e0","594949e62be16d0026ec04e1","59497219f4a8980024dd0631"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"Kunekune","version_clean":"3.2.0","version":"3.2.0"},"__v":0,"parentDoc":null,"updates":[],"next":{"pages":[],"description":""},"createdAt":"2017-02-25T10:46:56.750Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":4,"body":"## Overview\n\nThe Daydream Controller SDK script provides a bridge to SDK methods that deal with the input devices.\n\n## Class Methods\n\n### ProcessUpdate/2\n\n  > `public override void ProcessUpdate(VRTK_ControllerReference controllerReference, Dictionary<string, object> options)`\n\n  * Parameters\n   * `VRTK_ControllerReference controllerReference` - The reference for the controller.\n   * `Dictionary<string, object> options` - A dictionary of generic options that can be used to within the update.\n  * Returns\n   * _none_\n\nThe ProcessUpdate method enables an SDK to run logic for every Unity Update\n\n### ProcessFixedUpdate/2\n\n  > `public override void ProcessFixedUpdate(VRTK_ControllerReference controllerReference, Dictionary<string, object> options)`\n\n  * Parameters\n   * `VRTK_ControllerReference controllerReference` - The reference for the controller.\n   * `Dictionary<string, object> options` - A dictionary of generic options that can be used to within the fixed update.\n  * Returns\n   * _none_\n\nThe ProcessFixedUpdate method enables an SDK to run logic for every Unity FixedUpdate\n\n### GetCurrentControllerType/0\n\n  > `public override ControllerType GetCurrentControllerType()`\n\n  * Parameters\n   * _none_\n  * Returns\n   * `ControllerType` - The ControllerType based on the SDK and headset being used.\n\nThe GetCurrentControllerType method returns the current used ControllerType based on the SDK and headset being used.\n\n### GetControllerDefaultColliderPath/1\n\n  > `public override string GetControllerDefaultColliderPath(ControllerHand hand)`\n\n  * Parameters\n   * `ControllerHand hand` - The controller hand to check for\n  * Returns\n   * `string` - A path to the resource that contains the collider GameObject.\n\nThe GetControllerDefaultColliderPath returns the path to the prefab that contains the collider objects for the default controller of this SDK.\n\n### GetControllerElementPath/3\n\n  > `public override string GetControllerElementPath(ControllerElements element, ControllerHand hand, bool fullPath = false)`\n\n  * Parameters\n   * `ControllerElements element` - The controller element to look up.\n   * `ControllerHand hand` - The controller hand to look up.\n   * `bool fullPath` - Whether to get the initial path or the full path to the element.\n  * Returns\n   * `string` - A string containing the path to the game object that the controller element resides in.\n\nThe GetControllerElementPath returns the path to the game object that the given controller element for the given hand resides in.\n\n### GetControllerIndex/1\n\n  > `public override uint GetControllerIndex(GameObject controller)`\n\n  * Parameters\n   * `GameObject controller` - The GameObject containing the controller.\n  * Returns\n   * `uint` - The index of the given controller.\n\nThe GetControllerIndex method returns the index of the given controller.\n\n### GetControllerByIndex/2\n\n  > `public override GameObject GetControllerByIndex(uint index, bool actual = false)`\n\n  * Parameters\n   * `uint index` - The index of the controller to find.\n   * `bool actual` - If true it will return the actual controller, if false it will return the script alias controller GameObject.\n  * Returns\n   * `GameObject` -\n\nThe GetControllerByIndex method returns the GameObject of a controller with a specific index.\n\n### GetControllerOrigin/1\n\n  > `public override Transform GetControllerOrigin(VRTK_ControllerReference controllerReference)`\n\n  * Parameters\n   * `VRTK_ControllerReference controllerReference` - The reference to the controller to retrieve the origin from.\n  * Returns\n   * `Transform` - A Transform containing the origin of the controller.\n\nThe GetControllerOrigin method returns the origin of the given controller.\n\n### GenerateControllerPointerOrigin/1\n\n  > `public override Transform GenerateControllerPointerOrigin(GameObject parent)`\n\n  * Parameters\n   * `GameObject parent` - The GameObject that the origin will become parent of. If it is a controller then it will also be used to determine the hand if required.\n  * Returns\n   * `Transform` - A generated Transform that contains the custom pointer origin.\n\nThe GenerateControllerPointerOrigin method can create a custom pointer origin Transform to represent the pointer position and forward.\n\n### GetControllerLeftHand/1\n\n  > `public override GameObject GetControllerLeftHand(bool actual = false)`\n\n  * Parameters\n   * `bool actual` - If true it will return the actual controller, if false it will return the script alias controller GameObject.\n  * Returns\n   * `GameObject` - The GameObject containing the left hand controller.\n\nThe GetControllerLeftHand method returns the GameObject containing the representation of the left hand controller.\n\n### GetControllerRightHand/1\n\n  > `public override GameObject GetControllerRightHand(bool actual = false)`\n\n  * Parameters\n   * `bool actual` - If true it will return the actual controller, if false it will return the script alias controller GameObject.\n  * Returns\n   * `GameObject` - The GameObject containing the right hand controller.\n\nThe GetControllerRightHand method returns the GameObject containing the representation of the right hand controller.\n\n### IsControllerLeftHand/1\n\n  > `public override bool IsControllerLeftHand(GameObject controller)`\n\n  * Parameters\n   * `GameObject controller` - The GameObject to check.\n  * Returns\n   * `bool` - Returns true if the given controller is the left hand controller.\n\nThe IsControllerLeftHand/1 method is used to check if the given controller is the the left hand controller.\n\n### IsControllerRightHand/1\n\n  > `public override bool IsControllerRightHand(GameObject controller)`\n\n  * Parameters\n   * `GameObject controller` - The GameObject to check.\n  * Returns\n   * `bool` - Returns true if the given controller is the right hand controller.\n\nThe IsControllerRightHand/1 method is used to check if the given controller is the the right hand controller.\n\n### IsControllerLeftHand/2\n\n  > `public override bool IsControllerLeftHand(GameObject controller, bool actual)`\n\n  * Parameters\n   * `GameObject controller` - The GameObject to check.\n   * `bool actual` - If true it will check the actual controller, if false it will check the script alias controller.\n  * Returns\n   * `bool` - Returns true if the given controller is the left hand controller.\n\nThe IsControllerLeftHand/2 method is used to check if the given controller is the the left hand controller.\n\n### IsControllerRightHand/2\n\n  > `public override bool IsControllerRightHand(GameObject controller, bool actual)`\n\n  * Parameters\n   * `GameObject controller` - The GameObject to check.\n   * `bool actual` - If true it will check the actual controller, if false it will check the script alias controller.\n  * Returns\n   * `bool` - Returns true if the given controller is the right hand controller.\n\nThe IsControllerRightHand/2 method is used to check if the given controller is the the right hand controller.\n\n### GetControllerModel/1\n\n  > `public override GameObject GetControllerModel(GameObject controller)`\n\n  * Parameters\n   * `GameObject controller` - The GameObject to get the model alias for.\n  * Returns\n   * `GameObject` - The GameObject that has the model alias within it.\n\nThe GetControllerModel method returns the model alias for the given GameObject.\n\n### GetControllerModel/1\n\n  > `public override GameObject GetControllerModel(ControllerHand hand)`\n\n  * Parameters\n   * `ControllerHand hand` - The hand enum of which controller model to retrieve.\n  * Returns\n   * `GameObject` - The GameObject that has the model alias within it.\n\nThe GetControllerModel method returns the model alias for the given controller hand.\n\n### GetControllerRenderModel/1\n\n  > `public override GameObject GetControllerRenderModel(VRTK_ControllerReference controllerReference)`\n\n  * Parameters\n   * `VRTK_ControllerReference controllerReference` - The reference to the controller to check.\n  * Returns\n   * `GameObject` - A GameObject containing the object that has a render model for the controller.\n\nThe GetControllerRenderModel method gets the game object that contains the given controller's render model.\n\n### SetControllerRenderModelWheel/2\n\n  > `public override void SetControllerRenderModelWheel(GameObject renderModel, bool state)`\n\n  * Parameters\n   * `GameObject renderModel` - The GameObject containing the controller render model.\n   * `bool state` - If true and the render model has a scroll wheen then it will be displayed, if false then the scroll wheel will be hidden.\n  * Returns\n   * _none_\n\nThe SetControllerRenderModelWheel method sets the state of the scroll wheel on the controller render model.\n\n### HapticPulse/2\n\n  > `public override void HapticPulse(VRTK_ControllerReference controllerReference, float strength = 0.5f)`\n\n  * Parameters\n   * `VRTK_ControllerReference controllerReference` - The reference to the tracked object to initiate the haptic pulse on.\n   * `float strength` - The intensity of the rumble of the controller motor. `0` to `1`.\n  * Returns\n   * _none_\n\nThe HapticPulse/2 method is used to initiate a simple haptic pulse on the tracked object of the given controller reference.\n\n### HapticPulse/2\n\n  > `public override bool HapticPulse(VRTK_ControllerReference controllerReference, AudioClip clip)`\n\n  * Parameters\n   * `VRTK_ControllerReference controllerReference` - The reference to the tracked object to initiate the haptic pulse on.\n   * `AudioClip clip` - The audio clip to use for the haptic pattern.\n  * Returns\n   * _none_\n\nThe HapticPulse/2 method is used to initiate a haptic pulse based on an audio clip on the tracked object of the given controller reference.\n\n### GetHapticModifiers/0\n\n  > `public override SDK_ControllerHapticModifiers GetHapticModifiers()`\n\n  * Parameters\n   * _none_\n  * Returns\n   * `SDK_ControllerHapticModifiers` - An SDK_ControllerHapticModifiers object with a given `durationModifier` and an `intervalModifier`.\n\nThe GetHapticModifiers method is used to return modifiers for the duration and interval if the SDK handles it slightly differently.\n\n### GetVelocity/1\n\n  > `public override Vector3 GetVelocity(VRTK_ControllerReference controllerReference)`\n\n  * Parameters\n   * `VRTK_ControllerReference controllerReference` - The reference to the tracked object to check for.\n  * Returns\n   * `Vector3` - A Vector3 containing the current velocity of the tracked object.\n\nThe GetVelocity method is used to determine the current velocity of the tracked object on the given controller reference.\n\n### GetAngularVelocity/1\n\n  > `public override Vector3 GetAngularVelocity(VRTK_ControllerReference controllerReference)`\n\n  * Parameters\n   * `VRTK_ControllerReference controllerReference` - The reference to the tracked object to check for.\n  * Returns\n   * `Vector3` - A Vector3 containing the current angular velocity of the tracked object.\n\nThe GetAngularVelocity method is used to determine the current angular velocity of the tracked object on the given controller reference.\n\n### IsTouchpadStatic/4\n\n  > `public override bool IsTouchpadStatic(bool isTouched, Vector2 currentAxisValues, Vector2 previousAxisValues, int compareFidelity)`\n\n  * Parameters\n   * `Vector2 currentAxisValues` -\n   * `Vector2 previousAxisValues` -\n   * `int compareFidelity` -\n  * Returns\n   * `bool` - Returns true if the touchpad is not currently being touched or moved.\n\nThe IsTouchpadStatic method is used to determine if the touchpad is currently not being moved.\n\n### GetButtonAxis/2\n\n  > `public override Vector2 GetButtonAxis(ButtonTypes buttonType, VRTK_ControllerReference controllerReference)`\n\n  * Parameters\n   * `ButtonTypes buttonType` - The type of button to check for the axis on.\n   * `VRTK_ControllerReference controllerReference` - The reference to the controller to check the button axis on.\n  * Returns\n   * `Vector2` - A Vector2 of the X/Y values of the button axis. If no axis values exist for the given button, then a Vector2.Zero is returned.\n\nThe GetButtonAxis method retrieves the current X/Y axis values for the given button type on the given controller reference.\n\n### GetButtonHairlineDelta/2\n\n  > `public override float GetButtonHairlineDelta(ButtonTypes buttonType, VRTK_ControllerReference controllerReference)`\n\n  * Parameters\n   * `ButtonTypes buttonType` - The type of button to get the hairline delta for.\n   * `VRTK_ControllerReference controllerReference` - The reference to the controller to get the hairline delta for.\n  * Returns\n   * `float` - The delta between the button presses.\n\nThe GetButtonHairlineDelta method is used to get the difference between the current button press and the previous frame button press.\n\n### GetControllerButtonState/3\n\n  > `public override bool GetControllerButtonState(ButtonTypes buttonType, ButtonPressTypes pressType, VRTK_ControllerReference controllerReference)`\n\n  * Parameters\n   * `ButtonTypes buttonType` - The type of button to check for the state of.\n   * `ButtonPressTypes pressType` - The button state to check for.\n   * `VRTK_ControllerReference controllerReference` - The reference to the controller to check the button state on.\n  * Returns\n   * `bool` - Returns true if the given button is in the state of the given press type on the given controller reference.\n\nThe GetControllerButtonState method is used to determine if the given controller button for the given press type on the given controller reference is currently taking place.","excerpt":"","slug":"sdk_daydreamcontroller","type":"basic","title":"SDK_DaydreamController"}

SDK_DaydreamController


## Overview The Daydream Controller SDK script provides a bridge to SDK methods that deal with the input devices. ## Class Methods ### ProcessUpdate/2 > `public override void ProcessUpdate(VRTK_ControllerReference controllerReference, Dictionary<string, object> options)` * Parameters * `VRTK_ControllerReference controllerReference` - The reference for the controller. * `Dictionary<string, object> options` - A dictionary of generic options that can be used to within the update. * Returns * _none_ The ProcessUpdate method enables an SDK to run logic for every Unity Update ### ProcessFixedUpdate/2 > `public override void ProcessFixedUpdate(VRTK_ControllerReference controllerReference, Dictionary<string, object> options)` * Parameters * `VRTK_ControllerReference controllerReference` - The reference for the controller. * `Dictionary<string, object> options` - A dictionary of generic options that can be used to within the fixed update. * Returns * _none_ The ProcessFixedUpdate method enables an SDK to run logic for every Unity FixedUpdate ### GetCurrentControllerType/0 > `public override ControllerType GetCurrentControllerType()` * Parameters * _none_ * Returns * `ControllerType` - The ControllerType based on the SDK and headset being used. The GetCurrentControllerType method returns the current used ControllerType based on the SDK and headset being used. ### GetControllerDefaultColliderPath/1 > `public override string GetControllerDefaultColliderPath(ControllerHand hand)` * Parameters * `ControllerHand hand` - The controller hand to check for * Returns * `string` - A path to the resource that contains the collider GameObject. The GetControllerDefaultColliderPath returns the path to the prefab that contains the collider objects for the default controller of this SDK. ### GetControllerElementPath/3 > `public override string GetControllerElementPath(ControllerElements element, ControllerHand hand, bool fullPath = false)` * Parameters * `ControllerElements element` - The controller element to look up. * `ControllerHand hand` - The controller hand to look up. * `bool fullPath` - Whether to get the initial path or the full path to the element. * Returns * `string` - A string containing the path to the game object that the controller element resides in. The GetControllerElementPath returns the path to the game object that the given controller element for the given hand resides in. ### GetControllerIndex/1 > `public override uint GetControllerIndex(GameObject controller)` * Parameters * `GameObject controller` - The GameObject containing the controller. * Returns * `uint` - The index of the given controller. The GetControllerIndex method returns the index of the given controller. ### GetControllerByIndex/2 > `public override GameObject GetControllerByIndex(uint index, bool actual = false)` * Parameters * `uint index` - The index of the controller to find. * `bool actual` - If true it will return the actual controller, if false it will return the script alias controller GameObject. * Returns * `GameObject` - The GetControllerByIndex method returns the GameObject of a controller with a specific index. ### GetControllerOrigin/1 > `public override Transform GetControllerOrigin(VRTK_ControllerReference controllerReference)` * Parameters * `VRTK_ControllerReference controllerReference` - The reference to the controller to retrieve the origin from. * Returns * `Transform` - A Transform containing the origin of the controller. The GetControllerOrigin method returns the origin of the given controller. ### GenerateControllerPointerOrigin/1 > `public override Transform GenerateControllerPointerOrigin(GameObject parent)` * Parameters * `GameObject parent` - The GameObject that the origin will become parent of. If it is a controller then it will also be used to determine the hand if required. * Returns * `Transform` - A generated Transform that contains the custom pointer origin. The GenerateControllerPointerOrigin method can create a custom pointer origin Transform to represent the pointer position and forward. ### GetControllerLeftHand/1 > `public override GameObject GetControllerLeftHand(bool actual = false)` * Parameters * `bool actual` - If true it will return the actual controller, if false it will return the script alias controller GameObject. * Returns * `GameObject` - The GameObject containing the left hand controller. The GetControllerLeftHand method returns the GameObject containing the representation of the left hand controller. ### GetControllerRightHand/1 > `public override GameObject GetControllerRightHand(bool actual = false)` * Parameters * `bool actual` - If true it will return the actual controller, if false it will return the script alias controller GameObject. * Returns * `GameObject` - The GameObject containing the right hand controller. The GetControllerRightHand method returns the GameObject containing the representation of the right hand controller. ### IsControllerLeftHand/1 > `public override bool IsControllerLeftHand(GameObject controller)` * Parameters * `GameObject controller` - The GameObject to check. * Returns * `bool` - Returns true if the given controller is the left hand controller. The IsControllerLeftHand/1 method is used to check if the given controller is the the left hand controller. ### IsControllerRightHand/1 > `public override bool IsControllerRightHand(GameObject controller)` * Parameters * `GameObject controller` - The GameObject to check. * Returns * `bool` - Returns true if the given controller is the right hand controller. The IsControllerRightHand/1 method is used to check if the given controller is the the right hand controller. ### IsControllerLeftHand/2 > `public override bool IsControllerLeftHand(GameObject controller, bool actual)` * Parameters * `GameObject controller` - The GameObject to check. * `bool actual` - If true it will check the actual controller, if false it will check the script alias controller. * Returns * `bool` - Returns true if the given controller is the left hand controller. The IsControllerLeftHand/2 method is used to check if the given controller is the the left hand controller. ### IsControllerRightHand/2 > `public override bool IsControllerRightHand(GameObject controller, bool actual)` * Parameters * `GameObject controller` - The GameObject to check. * `bool actual` - If true it will check the actual controller, if false it will check the script alias controller. * Returns * `bool` - Returns true if the given controller is the right hand controller. The IsControllerRightHand/2 method is used to check if the given controller is the the right hand controller. ### GetControllerModel/1 > `public override GameObject GetControllerModel(GameObject controller)` * Parameters * `GameObject controller` - The GameObject to get the model alias for. * Returns * `GameObject` - The GameObject that has the model alias within it. The GetControllerModel method returns the model alias for the given GameObject. ### GetControllerModel/1 > `public override GameObject GetControllerModel(ControllerHand hand)` * Parameters * `ControllerHand hand` - The hand enum of which controller model to retrieve. * Returns * `GameObject` - The GameObject that has the model alias within it. The GetControllerModel method returns the model alias for the given controller hand. ### GetControllerRenderModel/1 > `public override GameObject GetControllerRenderModel(VRTK_ControllerReference controllerReference)` * Parameters * `VRTK_ControllerReference controllerReference` - The reference to the controller to check. * Returns * `GameObject` - A GameObject containing the object that has a render model for the controller. The GetControllerRenderModel method gets the game object that contains the given controller's render model. ### SetControllerRenderModelWheel/2 > `public override void SetControllerRenderModelWheel(GameObject renderModel, bool state)` * Parameters * `GameObject renderModel` - The GameObject containing the controller render model. * `bool state` - If true and the render model has a scroll wheen then it will be displayed, if false then the scroll wheel will be hidden. * Returns * _none_ The SetControllerRenderModelWheel method sets the state of the scroll wheel on the controller render model. ### HapticPulse/2 > `public override void HapticPulse(VRTK_ControllerReference controllerReference, float strength = 0.5f)` * Parameters * `VRTK_ControllerReference controllerReference` - The reference to the tracked object to initiate the haptic pulse on. * `float strength` - The intensity of the rumble of the controller motor. `0` to `1`. * Returns * _none_ The HapticPulse/2 method is used to initiate a simple haptic pulse on the tracked object of the given controller reference. ### HapticPulse/2 > `public override bool HapticPulse(VRTK_ControllerReference controllerReference, AudioClip clip)` * Parameters * `VRTK_ControllerReference controllerReference` - The reference to the tracked object to initiate the haptic pulse on. * `AudioClip clip` - The audio clip to use for the haptic pattern. * Returns * _none_ The HapticPulse/2 method is used to initiate a haptic pulse based on an audio clip on the tracked object of the given controller reference. ### GetHapticModifiers/0 > `public override SDK_ControllerHapticModifiers GetHapticModifiers()` * Parameters * _none_ * Returns * `SDK_ControllerHapticModifiers` - An SDK_ControllerHapticModifiers object with a given `durationModifier` and an `intervalModifier`. The GetHapticModifiers method is used to return modifiers for the duration and interval if the SDK handles it slightly differently. ### GetVelocity/1 > `public override Vector3 GetVelocity(VRTK_ControllerReference controllerReference)` * Parameters * `VRTK_ControllerReference controllerReference` - The reference to the tracked object to check for. * Returns * `Vector3` - A Vector3 containing the current velocity of the tracked object. The GetVelocity method is used to determine the current velocity of the tracked object on the given controller reference. ### GetAngularVelocity/1 > `public override Vector3 GetAngularVelocity(VRTK_ControllerReference controllerReference)` * Parameters * `VRTK_ControllerReference controllerReference` - The reference to the tracked object to check for. * Returns * `Vector3` - A Vector3 containing the current angular velocity of the tracked object. The GetAngularVelocity method is used to determine the current angular velocity of the tracked object on the given controller reference. ### IsTouchpadStatic/4 > `public override bool IsTouchpadStatic(bool isTouched, Vector2 currentAxisValues, Vector2 previousAxisValues, int compareFidelity)` * Parameters * `Vector2 currentAxisValues` - * `Vector2 previousAxisValues` - * `int compareFidelity` - * Returns * `bool` - Returns true if the touchpad is not currently being touched or moved. The IsTouchpadStatic method is used to determine if the touchpad is currently not being moved. ### GetButtonAxis/2 > `public override Vector2 GetButtonAxis(ButtonTypes buttonType, VRTK_ControllerReference controllerReference)` * Parameters * `ButtonTypes buttonType` - The type of button to check for the axis on. * `VRTK_ControllerReference controllerReference` - The reference to the controller to check the button axis on. * Returns * `Vector2` - A Vector2 of the X/Y values of the button axis. If no axis values exist for the given button, then a Vector2.Zero is returned. The GetButtonAxis method retrieves the current X/Y axis values for the given button type on the given controller reference. ### GetButtonHairlineDelta/2 > `public override float GetButtonHairlineDelta(ButtonTypes buttonType, VRTK_ControllerReference controllerReference)` * Parameters * `ButtonTypes buttonType` - The type of button to get the hairline delta for. * `VRTK_ControllerReference controllerReference` - The reference to the controller to get the hairline delta for. * Returns * `float` - The delta between the button presses. The GetButtonHairlineDelta method is used to get the difference between the current button press and the previous frame button press. ### GetControllerButtonState/3 > `public override bool GetControllerButtonState(ButtonTypes buttonType, ButtonPressTypes pressType, VRTK_ControllerReference controllerReference)` * Parameters * `ButtonTypes buttonType` - The type of button to check for the state of. * `ButtonPressTypes pressType` - The button state to check for. * `VRTK_ControllerReference controllerReference` - The reference to the controller to check the button state on. * Returns * `bool` - Returns true if the given button is in the state of the given press type on the given controller reference. The GetControllerButtonState method is used to determine if the given controller button for the given press type on the given controller reference is currently taking place.