Originally Posted by Karner
GetUnitAvARank(string unitTag)
Returns: integer rank, integer subRank
What about this for example?
a,b = unpack(GetUnitAvARank("player"))?
|
GetUnitAvARank does not return a table, so no need to unpack it.
Can just do this.
a,b = GetUnitAvARank("player")
Or you could create a table that contains the returned values, and then unpack that. But that is wasteful.
a,b = unpack({GetUnitAvARank("player")})
{GetUnitAvARank("player")} creates a table such like { [1] = rank, [2] = subRank }