TalentGuess is a library that attempts to guess enemy players talents using the spells they use, or the buffs they gain.
The accuracy depends entirely on the class and talents, most classes can be figured out to their "major" 31/41 point talents, for example a 25/36/0 Warlock can be figured out to at least 21/31/0.
Download TalentGuess-1.0 at WoWInterface
TalentGuess-1.0 API[]
:Register()[]
Returns[]
Return | Type | Details |
---|---|---|
TGObject | table | The TalentGuess Object encapsulating the TalentGuess API's. |
TalentGuess Object API[]
TGObject:EnableCollection()[]
Remarks[]
Flags that this TGObject is going to want talent data, will register the appropeate events in the library so data starts to be recorded.
TGObject:DisableCollection()[]
Remarks[]
Flags this TGObject as done collecting data, if no other TGObjects want data then the recording events will all be disabled. While it's not required that you call this when you only want data for a limited period of time inside an area like Arenas, it cuts down on the amount of data we store.
TGObject:RegisterCallback(handler[, func])[]
Args[]
Arg | Type | Details |
---|---|---|
handler | string/function/table | Function/method to call. |
func | string/function | (Optional) Function to call if you're using a handler |
Remarks[]
Registers the passed handler/function to be called when we get a new spellID used for a player.
If you passed just a function it'll be called as func(name, spellID) If you passed a handler and a function it'll be called as handler[func](handler, name, spellID)
TGObject:UnregisterCallback(handler[, func])[]
Args[]
Arg | Type | Details |
---|---|---|
handler | string/function/table | Function/method to call. |
func | string/function | (Optional) Function to call if you're using a handler |
Remarks[]
Unregisters the passed handler/function preventing it from being triggered whenever an enemy uses a new spellID.
TGObject:GetTalents(name)[]
Args[]
Arg | Type | Details |
---|---|---|
name | string | Player name to look up |
Returns[]
Return | Type | Details |
---|---|---|
pointsOne | number/nil | Points spent in tree #1, or nil if no data is available yet. |
pointsTwo | number/nil | Points spent in tree #2, or nil if no data is available yet. |
pointsThree | number/nil | Points spent in tree #3, or nil if no data is available yet. |
Remarks[]
Returns the talents that we think they've spent so far. The tree numbering is the same from the returns of [[API_GetTalentTabInfo]GetTalentTabInfo]](), if no data is found for the player then nil will be returned if we've seen at least one spell from them then the returns will be what we think their talents are.
If the player is from your server then all you need to pass is their name, if they are from a different one then you need to append "-server" (without the quotes). For example if you're on the Foo server and you want to get data for Apple on the Bar server then you need to pass "Apple-Bar", but if you want to get data from Orange on the Foo server then you can just pass "Orange".
TGObject:GetUsed(name)[]
Args[]
Arg | Type | Details |
---|---|---|
name | string | Player name to look up |
Returns[]
Return | Type | Details |
---|---|---|
talentsOne | table/nil | Returns a talentTable of spells in tree #1, or nil if no data is available. |
talentsTwo | table/nil | Returns a talentTable of spells in tree #2, or nil if no data is available. |
talentsThree | table/nil | Returns a talentTable of spells in tree #3, or nil if no data is available. |
Remarks[]
Returns a list of spellIDs and how far into the tree you need to be to get that spellID. The tree numbering is the same from the returns of [[API_GetTalentTabInfo]GetTalentTabInfo]](), if no data is found for the player then nil will be returned if we've seen at least one spell from them then the returns will be what we think their talents are.
If the player is from your server then all you need to pass is their name, if they are from a different one then you need to append "-server" (without the quotes). For example if you're on the Foo server and you want to get data for Apple on the Bar server then you need to pass "Apple-Bar", but if you want to get data from Orange on the Foo server then you can just pass "Orange".
talentTable is formated as [spellID] = pointsSpent, for example Shadowstep is spellID #36554 and requires 41 points spent so it would look like [36554] = 41.