ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Shared functions
  3. getElementRotation

Function

getElementRotation

Returns the element's rotation in degrees.

Syntax

float getElementRotation(element theElement)

Arguments

theElementelement
The element.

Differences from MTA:SA

  • These MTA:SA arguments are not here: string rotOrder = "default"

In MTA:SA

getElementRotation(element theElement, string rotOrder = "default")

Returns

rx, ry, rz or false.

Example

local _, _, rz = getElementRotation(player)
outputChatBox(("Patrzysz na %.0f°"):format(rz), player)

See also