Thread Tools Display Modes
11-24-23, 03:48 AM   #1
GnomeIndustries
A Defias Bandit
Join Date: Sep 2022
Posts: 3
Question Working out if a talent is known

I'm trying to write a module to my addon for my Death Knight that shows a warning when the Icy Talons buff is about to drop off or is missing. Which I've done... BUT

If I don't have the talent then I'll never have the buff and thus the warning always shows.

Is there an easy way to detect whether the talent is currently known or not?
  Reply With Quote
11-24-23, 01:53 PM   #2
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,928
This might help
https://warcraft.wiki.gg/wiki/API_GetTalentInfo

But you might have to build up a list of current talents to make it easier to find a talent if the direct route doesn't work.
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818
  Reply With Quote
11-25-23, 07:59 AM   #3
Mimma
A Murloc Raider
AddOn Author - Click to view addons
Join Date: Nov 2019
Posts: 7
Originally Posted by GnomeIndustries View Post
I'm trying to write a module to my addon for my Death Knight that shows a warning when the Icy Talons buff is about to drop off or is missing. Which I've done... BUT

If I don't have the talent then I'll never have the buff and thus the warning always shows.

Is there an easy way to detect whether the talent is currently known or not?

You could make the simple approach and only activate the message if Icy Talons had been actived earlier. It's dirty but simple :-)

Only problem is it won't work until you have actually cast the spell - and it won't work after you respec.
  Reply With Quote

WoWInterface » Developer Discussions » Lua/XML Help » Working out if a talent is known

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off