docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Introduction to controls

    A control is a part of a device that sends values to the Input System when actuated. Devices usually have multiple controls integrated into a single physical object. On a gamepad device, each of the buttons and sticks are controls. On a keyboard device, each of the individual keys are controls. Controls can take many other forms unique to certain types of device such as the pressure and radius of a pen, or the three-dimensional orientation of an XR input device.

    In most scenarios, to set up input for your app, use the Actions Editor window to bind controls to actions, so that when a user presses a button or moves a stick, the Input System sends the values from that control to the action which you can then write code to respond.

    Control names

    Each control is identified by a name (InputControl.name) and can optionally have a display name (InputControl.displayName) that differs from the control name. For example, the right-hand face button closest to the touchpad on a PlayStation DualShock 4 controller has the control name buttonWest and the display name Square.

    Additionally, a control might have one or more aliases which provide alternative names for the control. You can access the aliases for a specific control through its InputControl.aliases property.

    Finally, a control might also have a short display name which can be accessed through the InputControl.shortDisplayName property. For example, the short display name for the left mouse button is "LMB".

    Control value types

    A control represents a source of values. These values can be of any structured or primitive type, such as float, Vector2, or Quaternion. The only requirement is that the type is blittable.

    Parts of devices that are not controls

    Devices sometimes have other functional parts that are not considered controls. For example, output and configuration items such as haptic feedback, player number indicator lights, and on/off switches. The Input System only considers a part to be a control if it sends values for the purposes of input.

    In This Article
    Back to top
    Copyright © 2026 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)