WoW:API GetPlayerInfoByGUID: Difference between revisions

From AddOn Studio
Jump to navigation Jump to search
(→‎Details: The information is not encoded in the GUID.)
m (Move page script moved page API GetPlayerInfoByGUID to API GetPlayerInfoByGUID without leaving a redirect)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{wowapi}} __NOTOC__
{{wowapi}} __NOTOC__
{{Stub/API}}
Returns basic information about another player from their GUID.
locClass, engClass, locRace, engRace, gender, name, server = GetPlayerInfoByGUID("guid")


Returns basic information about another player from their GUID
== Arguments ==
;guid
: String - The GUID of the player you're querying about.


localizedClass, englishClass, localizedRace, englishRace, sex = GetPlayerInfoByGUID("guid")
== Returns ==
;locClass
: String - Class of the character in question (localized)
;engClass
: String - Class of the character in question (in English)
;locRace
: String - Race of the character in question (localized)
;engRace
: String - Race of the character in question (in English)
; gender
: String - Gender of the character in question (2: male, 3: female).
; name
: String - Name of the character in question (first letter uppercased).
; server
: String - Server of the character in question (first letter uppercased). If the character is on the same server then the empty string "".


== Parameters ==
== Notes ==
=== Arguments ===
* This function was added in [[Patch 3.2]]
:;guid : String - The GUID of the player you're querying about
* The information is not encoded in the GUID itself; as such, no data is available until the client has encountered the queried GUID.
 
* You can test it with the below (requiring a target, nil if the target is not a player).
=== Returns ===
/run print([https://wowwiki.fandom.com/wiki/API_GetPlayerInfoByGUID GetPlayerInfoByGUID](UnitGUID("target")))
:;localizedClass : String - Class of the character in question (localized)
:;englishClass : String - Class of the character in question (in English)
:;localizedRace : String - Race of the character in question (localized)
:;englishRace : String - Race of the character in question (in English)
:;sex : String - Gender of the character in question
 
== Example ==
 
== Details ==
This function was added in patch 3.2 (August, 2009)
 
The information is not encoded in the GUID itself: The function yields nothing until the game client saw anything from that GUID.
[[Category:World of Warcraft API]]

Latest revision as of 04:46, 15 August 2023

WoW API < GetPlayerInfoByGUID

Returns basic information about another player from their GUID.

locClass, engClass, locRace, engRace, gender, name, server = GetPlayerInfoByGUID("guid")

Arguments[edit]

guid
String - The GUID of the player you're querying about.

Returns[edit]

locClass
String - Class of the character in question (localized)
engClass
String - Class of the character in question (in English)
locRace
String - Race of the character in question (localized)
engRace
String - Race of the character in question (in English)
gender
String - Gender of the character in question (2: male, 3: female).
name
String - Name of the character in question (first letter uppercased).
server
String - Server of the character in question (first letter uppercased). If the character is on the same server then the empty string "".

Notes[edit]

  • This function was added in Patch 3.2
  • The information is not encoded in the GUID itself; as such, no data is available until the client has encountered the queried GUID.
  • You can test it with the below (requiring a target, nil if the target is not a player).
/run print(GetPlayerInfoByGUID(UnitGUID("target")))