View Single Post
11-05-11, 02:25 PM   #2
unlimit
Lookin' Good
 
unlimit's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2008
Posts: 484
Googled and found this @ http://www.wowinterface.com/forums/s...ad.php?t=38204

Originally Posted by Ailae View Post
If all you are interested in is determining which spec a player is, you can use GetPrimaryTalentTree in conjunction with GetTalentTabInfo.

Code:
local tab = GetPrimaryTalentTree()
local name = select(2, GetTalentTabInfo(tab))
print(name)
This prints Survival for example, on a hunter who has chosen Survival as their main tree.

http://wowprogramming.com/docs/api/GetPrimaryTalentTree
http://wowprogramming.com/docs/api/GetTalentTabInfo
So I'd guess that it'd be something like:

Code:
local cfg.talenttree = GetPrimaryTalentTree()
if cfg.playername == "Windblossom" and cfg.playerclass == "DRUID" and cfg.talentree == 3 then
	cfg.animhealth = 0;
end
Learning LUA myself, but I believe(?) that would be correct?
__________________


kúdan: im playing pantheon
JRCapablanca: no youre not
** Pantheon has been Banned. **

Last edited by unlimit : 11-08-11 at 01:10 AM.
  Reply With Quote