Search Unity

How do I use accelerometer?

Discussion in 'Input System' started by datagreed, Jul 10, 2020.

  1. datagreed

    datagreed

    Joined:
    Sep 17, 2018
    Posts:
    44
    I see that the new input system has an Accelerometer class derived from a Sensor, but I don't see any way to map it in PlayerControls.

    When I try to add a new binding, I cannot select accelerometer, just a generic "Sensor" which I am not sure how to read values from. I expected for this to work somewhat the same as the gamepad stick mapping :)

    I am actually trying to send an action (simulate a gamepad button click) when player flicks his device/controller. How do I do that with the new input system?
     
    vengefullfoot likes this.