Difference between revisions of "GetPlayerHeading"

From Onset Developer Wiki
 
Line 1: Line 1:
 
{{Info|Function|Server & Client|1.0}}
 
{{Info|Function|Server & Client|1.0}}
  
{{FuncDescription|__EDIT_ME__}}
+
{{FuncDescription|Get the specified player's heading (rotation).}}
  
 
{{FuncSyntax|GetPlayerHeading(player)}}
 
{{FuncSyntax|GetPlayerHeading(player)}}
  
 
{{FuncParameters}}
 
{{FuncParameters}}
{{FuncParam|player|__EDIT_ME__}}
+
{{FuncParam|player|The player identifier.}}
  
{{FuncReturnValue|__EDIT_ME__}}
+
{{FuncReturnValue|This function returns heading in float.}}
  
 
== Example ==
 
== Example ==
__EDIT_ME__
+
<syntaxhighlight lang='Lua'>
 +
local heading = GetPlayerHeading(playerId)
 +
</syntaxhighlight>
  
 
{{RelatedFunctions}}
 
{{RelatedFunctions}}
__EDIT_ME__
+
{{PlayerFunctions}}

Latest revision as of 18:17, 16 January 2020

GetPlayerHeading

Type: Function
Context: Server & Client
Introduced: v1.0

Description

Get the specified player's heading (rotation).

Syntax

GetPlayerHeading(player)

Parameters

  • player
    The player identifier.

Return Value

  • This function returns heading in float.

Example

local heading = GetPlayerHeading(playerId)

See also

Template:PlayerFunctions