GetDeviceRotation

Constructor:

GetDeviceRotation()

Description

Retrieves the rotating angle of the current device.

Return Value

Variable name Class Name Default Description
vector3 The rotating angle returned.

Examples

Observe whether the rotating angle is output or not.

wait(1)
local dir = UserInputService:GetDeviceRotation()
print(tostring(dir))