Jump to content

Recommended Posts

Since Droidz did such a fabulous job in helping me put together a healing profile that would heal my bodyguard (/focus), I was wondering if anyone knew a way to select from a list of "possible" targets and set the one it found to the focus?

 

Here is what I am striving for:

 

if exists (Aeda Brightdawn, Defender Illona, Delvar Ironfist, Leorajh, Talonpriest Ishaal, Tormmok, Vivianne) Set Focus

then 

/targetlasttarget
 
As I do not know programming, I thought I would post my thought here and see if anyone knows a way to do this?
 
Thanks!
Link to comment
https://wrobot.eu/forums/topic/2088-select-from-a-list-of-targets/
Share on other sites

Hello,

 

When Bugreporter have say, you cannot share your fightclass because you use unit and spell name (this don't works on wow french client by sample).

local npcFollowers={"Aeda Brightdawn", "Defender Illona", "Delvar Ironfist", "Leorajh", "Talonpriest Ishaal", "Tormmok", "Vivianne"}
for key,value in pairs(npcFollowers) do
	RunMacroText("/target " .. value) 
	local targetName = UnitName("target")
	if targetName == value then
		CastSpellByName("Flash of Light" , "TARGET")
		TargetLastTarget() 
		return
	end
end

You can also try this code (but not safe):

local targetName = UnitName("target")
TargetNearestFriend()
local targetNameSecond = UnitName("target")
if not (targetName == targetNameSecond) then
	CastSpellByName("Flash of Light" , "TARGET")
	TargetLastTarget() 
end

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...