View Single Post
02-05-06, 05:06 PM   #28
ziekke
A Defias Bandit
Join Date: Feb 2006
Posts: 2
Originally Posted by Gello
For innervate or procs yeah it's doable. I would suggest going by the combat log event for those. You could do UNIT_AURA also but that will fire a lot more than the combat one. Events are being rewritten this weekend I'll try and remember to make an example of either to post.

For an event based on target type, you would want to trigger on PLAYER_TARGET_CHANGED and I suggest a delay of 0.25 or 0.5 since the event fires in pairs when you go from one target to another. The functions to check would probably be http://www.wowwiki.com/API_UnitCreatureType
I appreciate your quick response to my original question. I admittedly don't know the first thing about LUA. However I do have some coding experience. Could you point me to an event that would be constructed similar to the on PLAYER_TARGET_CHANGED so that I have a foundation to start on?

[edit]
This is what I get.. will be testing it..

if (UnitCreatureType("target") == "Undead") then
EquipSet()
end --[[Equip a set when targeting Undead.]]

[edit]

Works like a charm. Just gotta get it to unequip when I change targets.

Last edited by ziekke : 02-05-06 at 05:22 PM.
  Reply With Quote