Me again viral,
using this:
Code:
#showtooltip Holy Light
/use [combat]10
/use [combat] 13
/use [combat] 14
/run if not UnitBuff("player", "Seal of Light") then CastSpellByName("Seal of Light") end
/run if UnitHealth("player")/UnitHealthMax("player")<0.10 and GetSpellCooldown("Divine Shield")==0 and IsUsableSpell("Divine Shield") then CastSpellByName("Divine Shield") end;
/run if GetSpellCooldown("Divine Plea") ==0 and UnitPower("player")/UnitPowerMax("player")<=0.80 then CastSpellByName("Divine Plea") end;
/run if GetSpellCooldown("Arcane Torrent") ==0 and UnitPower("player")/UnitPowerMax("player")<=0.80 then CastSpellByName("Arcane Torrent") end;
/run if GetSpellCooldown("Lay on Hands") ==0 and UnitPower("player")/UnitPowerMax("player")<=0.40 then RunMacroText("/cast [@Player] Lay On Hands") end;
/run local dp=({UnitBuff("player","Divine Plea")})[7]; if dp~=nil and dp-GetTime()>10 and GetSpellCooldown("Avenging Wrath")==0 and IsUsableSpell("Avenging Wrath")==1 then CastSpellByName("Avenging Wrath") end;
/run if UnitPower("player")/UnitPowerMax("player")<0.50 and GetSpellCooldown("Lay on Hands")==0 and IsUsableSpell("Lay On Hands")==1 then RunMacroText("/cast [@Player] Lay on Hands") end;
/run if UnitPower('player')<4000 then RunMacroText("/use Runic Mana Potion") end
/run if UnitHealth("player")/UnitHealthMax("player")<0.30 then CastSpellByName("Divine Shield") end;
/run f=0; if UnitExists("focus") then for i=1,40 do d={UnitBuff("focus",i)}; if d~=nil and d[1]=="Beacon of Light" and d[8]=="player" and d[7]-GetTime()>=3 then f=1; break end end if f==0 then RunMacroText("/cast [@focus] Beacon of Light") end end;
/run FoL=3000; HS=6000; HL=8000; t="raid"; nps=1; npe=GetNumRaidMembers(); if npe==0 then t="party"; nps=0; npe=GetNumPartyMembers() end; e=UnitExists; n=UnitName; h=UnitHealth; hm=UnitHealthMax; s=nil; f="focus"; fh=0; if e(f) then fh=hm(f)-h(f) end; m=0; w=f; for i=nps,npe do if i==0 then tt="player" else tt=t..i end; if e(tt) and (e(f)==nil or n(tt)~=n(f)) then a=hm(tt)-h(tt); if a>m and UnitInRange(tt)==1 and UnitIsDeadOrGhost(tt)~=1 then m=a w=tt end end end; if fh>2*m then m=fh end; if GetSpellCooldown("Holy Shock")==0 and m>=HS then s="Holy Shock" elseif m>=HL then s="Holy Light" elseif m>=FoL then s="Flash of Light" end; if s~=nil then RunMacroText("/cast [@"..w.."] "..s) end;
/run if GetSpellCooldown("Judgement of Light") == 0 then RunMacroText("/cast [@focustarget] Judgement of Light") end;
/run f=0; if UnitExists("focus") then for i=1,40 do d={UnitBuff("focus",i)}; if d~=nil and d[1]=="Sacred Shield" and d[8]=="player" and d[7]-GetTime()>=3 then f=1; break end end if f==0 then RunMacroText("/cast [@focus] Sacred Shield") end end;
/run t="raid"; nps=1; npe=GetNumRaidMembers(); if npe==0 then t="party"; nps=0; npe=GetNumPartyMembers() end; w=nil; m=0; for i=nps,npe do if i==0 then tt="player" else tt=t..i end; if UnitExists(tt) and UnitInRange(tt)==1 and UnitIsDeadOrGhost(tt)~=1 then for j=1,40 do d={UnitDebuff(tt,j)}; if d~=nil and (d[5]=="Magic" or d[5]=="Poison" or d[5]=="Disease") and d[7]>m then w=tt; m=d[7] end end end end; if w~=nil then RunMacroText("/cast [@"..w.."] Cleanse") end;
/run StaticPopup_Hide("MACRO_ACTION_FORBIDDEN");
Which works great in hc's low level raids, even ICC10. However tried a TOTGC10 to really test it and when we got anub to P3 and the shit's hitting the fan people are on low health mana is dropping. It does nothing, I have sufficient mana to do something, yet the script doesn't. almost as if it doesn't know what to do. Any Ideas?