LibTalentQuery-1.0

This project is abandoned.

Whether this project is out of date or its author marked it as abandoned, this project is no longer maintained.

If you wish to take this project over, please report it and state your intentions.

Library to help with querying unit talents. There's many factors using the NotifyInspect() / INSPECT_TALENT_READY combo which will invalidate the results (spammy inspect addons, zoning, roster updates). This library helps by removing that layer of uncertainty and complexity from your addon to give a simple Query/Result to deal with.

Example Usage:

local TalentQuery = LibStub:GetLibrary("LibTalentQuery-1.0")
TalentQuery.RegisterCallback(self, "TalentQuery_Ready")

local raidTalents = {}
...
TalentQuery:Query(unit)
...
function MyAddon:TalentQuery_Ready(e, name, realm, unitid)
	local isnotplayer = not UnitIsUnit(unitid, "player")
	local group = GetActiveTalentGroup(isnotplayer)
	local spec = {}
	for tab = 1, GetNumTalentTabs(isnotplayer) do
		local _, treename, _, _, pointsspent = GetTalentTabInfo(tab, isnotplayer, nil, group)
		tinsert(spec, pointsspent)
	end
	raidTalents[UnitGUID(unitid)] = spec
end

You must login to post a comment. Don't have an account? Register to get one!

Facts

Date created
Mar 30, 2008
Category
Last update
Aug 31, 2012
Development stage
Abandoned
Language
  • enUS
License
GNU Lesser General Public License version 2.1 (LGPLv2.1)
Reverse relationships
19
Downloads
55,435
Recent files

Authors

Relationships

Embedded library
CallbackHandler-1.0
LibStub