GetNPCLocation: Difference between revisions

From Onset Developer Wiki
No edit summary
No edit summary
 
Line 1: Line 1:
{{Info|Function|Server & Client|1.0}}
{{Info|Function|Server & Client|1.0}}


{{FuncDescription|__EDIT_ME__}}
{{FuncDescription|Get the NPC's location vectors.}}


{{FuncSyntax|GetNPCLocation(npc)}}
{{FuncSyntax|GetNPCLocation(npc)}}


{{FuncParameters}}
{{FuncParameters}}
{{FuncParam|npc|__EDIT_ME__}}
{{FuncParam|npc|The NPC identifier.}}


{{FuncReturnValue|__EDIT_ME__}}
{{FuncReturnValue|Returns the XYZ vectors of the NPC's location.}}


== Example ==
== Example ==
__EDIT_ME__
<syntaxhighlight lang="Lua>
local x, y, z = GetNPCLocation(npcid)
</syntaxhighlight>


{{RelatedFunctions}}
{{RelatedFunctions}}
__EDIT_ME__
{{Template:NPCFunctions}}

Latest revision as of 13:03, 19 November 2019

GetNPCLocation

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

Description

Get the NPC's location vectors.

Syntax

GetNPCLocation(npc)

Parameters

  • npc
    The NPC identifier.

Return Value

  • Returns the XYZ vectors of the NPC's location.

Example

local x, y, z = GetNPCLocation(npcid)

See also