Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Question What is the meaning of various Control Types?

Discussion in 'Input System' started by gaazkam, Nov 17, 2022.

  1. gaazkam


    Mar 30, 2016
    For each Action we need to pick a Control Type:

    The meaning of the various available options does not seem immediately clear from their names. For example, what is the difference between Vector 2, Stick and Analog?

    A very partial answer can be found in the official documentation page Controls § Control types. For example, it says that Vector 2 can be used to read mouse pointer positions, while Stick can be used to read input from gamepad thumbsticks. Some control types, such as Analog, are undocumented.

    This is confusing to me, given how the default Input Actions asset created by Unity looks like:

    As you can see the Move action is set to Control Type Vector 2 even though it does not contain mouse pointer bindings. It does contain, however, a binding to the left stick of a gamepad, so perhaps we should set the Control Type to Stick instead? On the other hand, it does not seem appropriate for the keyboard bindings listed there - judging purely by names Dpad would seem to be a better choice. Not sure about the XR Controller, but perhaps this one should indeed be a Vector 2? For all those bindings, however, we must chose only one Control Type.

    I am really confused here and unfortunately I can't find any clear answers in the documentation - so I thought I'd try asking here :)