The AutoJumpEnabled property determines whether the
Player/Character of a
Player using a mobile device will automatically jump when they hit an obstacle. This can make levels more navigable while on a mobile device.
When the player joins the game, the
StarterPlayer/AutoJumpEnabled value determines the initial state of this property. Then, this property determines the value of the
Humanoid/AutoJumpEnabled property of the
Humanoid on spawn. In other words, it is possible to set the auto-jump behavior on a per-character, per-player and per-game basis using these three properties.
This code sample is meant for a TextButton. It allows the player to toggle the auto-jumping behavior while on a mobile device.