Open main menu
Home
Random
Log in
Settings
About AddOn Studio
Disclaimers
AddOn Studio
Search
Editing
WoW:API GetBattlefieldScore
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{wowapi}} Returns information about a player's score in battlegrounds. name, killingBlows, honorKills, deaths, honorGained, faction, rank, race, class, filename, damageDone, healingDone = GetBattlefieldScore(index); == Parameters == === Arguments === :( index ) :;index : Integer - The characters index in battlegrounds. ---- === Returns === :name, killingBlows, honorKills, deaths, honorGained, faction, rank, race, class, classToken, damageDone, healingDone, bgRating, ratingChange :;name : String - The player's name, with their server name attached if from a different server to the player. :;killingBlows : Integer - Number of killing blows. :;honorKills : Integer - Number of honourable kills. :;deaths : Integer - The number of deaths. :;honorGained : Integer - The amount of honour gained so far (Bonus Honour). :;faction : Integer - (Battlegrounds: Horde = 0, Alliance = 1 / Arenas: Green Team = 0, Yellow Team = 1). :;rank : Integer - The players rank (0 - 14). :;race : String - The players race (Orc, Undead, Human, etc). :;class : String - The players class (Mage, Hunter, Warrior, etc). :;classToken: String - The player's class name in english given in all capitals (MAGE , HUNTER, WARRIOR, etc) :;damageDone: Integer - The amount of damage done. :;healingDone: Integer - The amount of healing done. :;bgRating: Integer - The players current battleground rating. (0 if not rated) :;ratingChange: Integer - The rating change (0 if not rated) ---- === Example === How to count the number of players in each faction. local numScores = GetNumBattlefieldScores() local numHorde = 0 local numAlliance = 0 for i=1, numScores do name, killingBlows, honorableKills, deaths, honorGained, faction, rank, race, class = GetBattlefieldScore(i); if ( faction ) then if ( faction == 0 ) then numHorde = numHorde + 1 else numAlliance = numAlliance + 1 end end end <br><center>''Last updated: Patch 2.0''</center> ---- __NOTOC__
Summary:
Please note that all contributions to AddOn Studio are considered to be released under the Creative Commons Attribution-NonCommercial-ShareAlike (see
AddOn Studio Wiki:Copyrights
for details).
Submissions must be written by you, or copied from a public domain or similar free resource (see
AddOn Studio Wiki:Copyrights
for details).
Cancel
Editing help
(opens in new window)
Templates used on this page:
Template:Apinav
(
edit
)
Template:Editlink
(
edit
)
Template:Tocright
(
edit
)
Template:Wowapi
(
edit
)