Document supported platforms for Input.get_accelerometer()
and related
This closes #41303.
This commit is contained in:
parent
a609b30ddb
commit
eee704e6f6
1 changed files with 8 additions and 4 deletions
|
@ -47,8 +47,9 @@
|
||||||
<return type="Vector3">
|
<return type="Vector3">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
If the device has an accelerometer, this will return the acceleration. Otherwise, it returns an empty [Vector3].
|
Returns the acceleration of the device's accelerometer, if the device has one. Otherwise, the method returns [constant Vector3.ZERO].
|
||||||
Note this method returns an empty [Vector3] when running from the editor even when your device has an accelerometer. You must export your project to a supported device to read values from the accelerometer.
|
Note this method returns an empty [Vector3] when running from the editor even when your device has an accelerometer. You must export your project to a supported device to read values from the accelerometer.
|
||||||
|
[b]Note:[/b] This method only works on iOS, Android, and UWP. On other platforms, it always returns [constant Vector3.ZERO].
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_action_strength" qualifiers="const">
|
<method name="get_action_strength" qualifiers="const">
|
||||||
|
@ -78,14 +79,16 @@
|
||||||
<return type="Vector3">
|
<return type="Vector3">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
If the device has an accelerometer, this will return the gravity. Otherwise, it returns an empty [Vector3].
|
Returns the gravity of the device's accelerometer, if the device has one. Otherwise, the method returns [constant Vector3.ZERO].
|
||||||
|
[b]Note:[/b] This method only works on Android and iOS. On other platforms, it always returns [constant Vector3.ZERO].
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_gyroscope" qualifiers="const">
|
<method name="get_gyroscope" qualifiers="const">
|
||||||
<return type="Vector3">
|
<return type="Vector3">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
If the device has a gyroscope, this will return the rate of rotation in rad/s around a device's X, Y, and Z axes. Otherwise, it returns an empty [Vector3].
|
Returns the rotation rate in rad/s around a device's X, Y, and Z axes of the gyroscope, if the device has one. Otherwise, the method returns [constant Vector3.ZERO].
|
||||||
|
[b]Note:[/b] This method only works on Android. On other platforms, it always returns [constant Vector3.ZERO].
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_joy_axis" qualifiers="const">
|
<method name="get_joy_axis" qualifiers="const">
|
||||||
|
@ -182,7 +185,8 @@
|
||||||
<return type="Vector3">
|
<return type="Vector3">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
If the device has a magnetometer, this will return the magnetic field strength in micro-Tesla for all axes.
|
Returns the the magnetic field strength in micro-Tesla for all axes of the device's magnetometer, if the device has one. Otherwise, the method returns [constant Vector3.ZERO].
|
||||||
|
[b]Note:[/b] This method only works on Android and UWP. On other platforms, it always returns [constant Vector3.ZERO].
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_mouse_button_mask" qualifiers="const">
|
<method name="get_mouse_button_mask" qualifiers="const">
|
||||||
|
|
Loading…
Reference in a new issue