NPC ID macro for Mists
Posted: Sun Aug 19, 2012 9:43 am
The macro you need to determine the NPC id of something has changed a little in Mists.
I noticed that the old macro was working for most NPCs, but for others it was giving absurdly low numbers. It appears that they've added an extra digit to the hex string as the ID numbers have rolled over. The macro that seems to work for me now, for old and new beasts is:
/run print("Target NPC ID:", tonumber((UnitGUID("target")):sub(-13, -9), 16))
I noticed that the old macro was working for most NPCs, but for others it was giving absurdly low numbers. It appears that they've added an extra digit to the hex string as the ID numbers have rolled over. The macro that seems to work for me now, for old and new beasts is:
/run print("Target NPC ID:", tonumber((UnitGUID("target")):sub(-13, -9), 16))