Tile - YLocalPlayer - Get Vertical Input – Ylands

From Bohemia Interactive Community
Jump to navigation Jump to search

Get Vertical Input()

YlandsTile-939.png

static getPrimaryVerticalInput(): number;

Returns

number

Description

Vertical input of the player in a single player game.

Notes

  • Returns -1 if the player presses S
  • Returns +1 if the player presses W
  • Returns 0 if nothing or both are pressed
  • On a phone, or with a game controller, partial numbers between -1 and 1 are possible.
  • This tile does not automatically prevent player movement. This can be disabled separately by unchecking "Player - Directional Movement" within a **Custom Controls ** Game logic.