[REQ] Holy Paladin LUA Macro Needs Update! menu

Shout-Out

User Tag List

Page 2 of 2 FirstFirst 12
Results 16 to 19 of 19
  1. #16
    Ultraviolence's Avatar Active Member
    Reputation
    15
    Join Date
    Aug 2008
    Posts
    102
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The priority is based on health deficits, so it shouldn't need rearranging, unless I misunderstand you.

    [REQ] Holy Paladin LUA Macro Needs Update!
  2. #17
    cdmichaelb's Avatar Contributor CoreCoins Purchaser
    Reputation
    119
    Join Date
    Jan 2011
    Posts
    368
    Thanks G/R
    21/5
    Trade Feedback
    7 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Seems I quoted the wrong thing but;
    /run if UnitExists(w)==1 and UnitInRange(w)==1 then if m>=10000 and cd(hs)==0 and sp>=0 then rmt("/cast [@"..w.."] Holy Shock") elseif m>=15000 and mana>0.10 and cd(hl)==0 then rmt("/cast [@"..w.."] Holy Light") elseif m>=35000 and mana>0.5 and cd(dl)==0 then rmt("/cast [@"..w.."] Divine Light") elseif m>=25000 and mana>0.75 then rmt("/cast [@"..w.."] Flash of Light") elseif (m<=0.20 and UnitPowerMax(w)>=75000) and cd(hop)==0 and r(hop,w)==1 and UnitAffectingCombat(w)==1 and not UnitDebuff(w,"Forbearance") and not UnitDebuff(w,"Ice Block") then rmt("/cast [@"..w.."] Hand of Protection") end d,n=0,0; if (n>(npe*0.2) and d/n>5000) and cd(lod)==0 then c(lod) elseif (n>(npe*0.4) and d/n>15000) and cd(hr)==0 then c(hr) elseif (n>(npe*1) and d/n>50000) and cd(goak)==0 then c(goak) elseif (n>(npe*0.6) and d/n>35000) and cd(df)==0 then c(df) elseif m>=20000 and sp>=0 and cd(wog)==0 and (UnitPower("player", 9)>2 or UnitPower("player", 9)==3) then rmt("/cast [@"..w.."] Word of Glory") end end
    if m>=10000 and cd(hs)==0 and sp>=0 then rmt("/cast [@"..w.."] Holy Shock")
    With this code in the very front of the script m will ALWAYS be either under 10k (do nothing) or greater than 10k (holy shock), of course holy shock has a cooldown, so it will move on to holy light which is next m>15000 but then we have the same problem here so the script will never move on past there.

    Now if you do m>15000k and m<35000 (35k for flash of light to heal, and this needs to be done for each heal except the heal that has the most deficient for m). This will make all the healing work but it will never get to the BOP or WOG part of code, since divine light will be the end all. So BOP and WOG either need to be moved to the front and given specific conditions, or moved to a separate /run script.

    ---------- Post added at 05:19 AM ---------- Previous post was at 05:00 AM ----------

    I decided to start the rewrite.
    Not gonna say it's perfect but here it is. Also (see bottom) some code didn't make sense so I left it out.
    Code:
    #showtooltip Holy Light
    /run cd=GetSpellCooldown c=CastSpellByName r=IsSpellInRange sp=GetUnitSpeed("player") mana=UnitPower("player")/UnitPowerMax("player") hs="Holy Shock" hl="Holy Light" dl="Divine Light" fol="Flash of Light" wog="Word of Glory" lod="Light of Dawn" hr="Holy Radiance" goak="Guardian of Ancient Kings" rmt=RunMacroText df="Divine Favor" hop="Hand of Protection"
    
    #SEAL
    /run if not IsMounted()==1 and not UnitBuff("player","Seal of Insight") then CastSpellByName("Seal of Insight") end
    
    #BLESSINGS
    /run if not IsMounted()==1 and GetSpellCooldown(GetCVar("blessing"))==0 and not UnitBuff("player",GetCVar("blessing")) then CastSpellByName(GetCVar("blessing")) end;
    
    #REBUKE
    /run if select(9,UnitCastingInfo('target'))==false and GetSpellCooldown("Rebuke")==0 and IsSpellInRange("Rebuke")==1 then CastSpellByName("Rebuke") end;
    /run if select(8,UnitChannelInfo('target'))==false and GetSpellCooldown("Rebuke")==0 and IsSpellInRange("Rebuke")==1 then CastSpellByName("Rebuke") end;
    
    #Divine Shield
    /run if UnitHealth("player")/UnitHealthMax("player")<0.10 and GetSpellCooldown("Divine Shield")==0 and IsUsableSpell("Divine Shield")==1 and not UnitDebuff("player", "Forbearance") then CastSpellByName("Divine Shield") end
        
    #Healthstone if needed and Divine Shield on cd
    /run if UnitHealth("player")/UnitHealthMax("player")<0.10 and GetSpellCooldown("Divine Shield")>0 and (GetItemCount("Healthstone")==1 and GetItemCooldown(19005)==0) then RunMacroText("/use Healthstone") end
    
    #Divine Protection @ <50% hp
    /run if UnitHealth("player")/UnitHealthMax("player")<0.50 and GetSpellCooldown("Divine Protection")==0 then SpellStopCasting() CastSpellByName("Divine Protection") end
    
    #Divine Plea
    /run if GetSpellCooldown("Divine Plea")==0 and UnitPower("player")/UnitPowerMax("player")<=0.50 then CastSpellByName("Divine Plea") return end;
    
    #Avenging Wrath if Divine Plea
    /run if UnitBuff("player", "Divine Plea") and GetSpellCooldown("Avenging Wrath")==0 not UnitDebuff("player", "Forbearance") then CastSpellByName("Avenging Wrath") end
    
    #Beacon on focus
    /run f=0; if UnitExists("focus") and UnitHealth("focus")>1 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 and UnitInRange("focus")==true then RunMacroText("/cast [@focus] Beacon of Light") return end end;
    
    #Judgement focus-target
    /run if UnitExists("focustarget") and UnitInRange("focus")==true and UnitAffectingCombat("focus")==1 and GetSpellCooldown("Judgement")==0 then CastSpellByName("Judgement", "focustarget") end
    
    #Get party/raid members
    /run t="raid"; nps=1;npe=GetNumRaidMembers();if npe==0 then t="party"; nps=0; npe=GetNumPartyMembers() end;m=0;w=f;for i=nps,npe do if i==0 then tt="player" else tt=t..i end; if UnitExists(tt) and UnitInRange(tt)==true and UnitIsDeadOrGhost(tt)~=1 then a=UnitHealthMax(tt)-UnitHealth(tt);if a>m then m=a w=tt end end end;
    
    #Main healing
    /run if UnitExists(w)==1 and UnitInRange(w)==true then if (m<=UnitHealth(w)/UnitHealthMax(w)<=0.2 and UnitPowerMax(w)>=75000) and cd(hop)==0 and r(hop,w)==1 and UnitAffectingCombat(w)==1 and not UnitDebuff(w,"Forbearance") and not UnitDebuff(w,"Ice Block") then rmt("/cast [@"..w.."] Hand of Protection") elseif UnitHealth(w)/UnitHealthMax(w)<=0.15 and mana>0.5 then rmt("/cast [@"..w.."] Flash of Light") elseif m>=10000 and m<=15000 and cd(hs)==0 and sp>=0 then rmt("/cast [@"..w.."] Holy Shock") elseif m>=15000 and m<=35000 and mana>0.10 and cd(hl)==0 then rmt("/cast [@"..w.."] Holy Light") elseif m>=35000 and mana>0.5 and cd(dl)==0 then rmt("/cast [@"..w.."] Divine Light")  end end
    The WTF code, aside from being broken since I just ripped it out... d,n=0,0 then it goes on to do math on d and n, as if d and n might be values other than 0?
    Code:
     d,n=0,0; if (n>(npe*0.2) and d/n>5000) and cd(lod)==0 then c(lod) elseif (n>(npe*0.4) and d/n>15000) and cd(hr)==0 then c(hr) elseif (n>(npe*1) and d/n>50000) and cd(goak)==0 then c(goak) elseif (n>(npe*0.6) and d/n>35000) and cd(df)==0 then c(df) elseif m>=20000 and sp>=0 and cd(wog)==0 and (UnitPower("player", 9)>2 or UnitPower("player", 9)==3) then rmt("/cast [@"..w.."] Word of Glory")
    Last edited by cdmichaelb; 04-20-2011 at 08:39 PM.

  3. #18
    Sikas's Avatar Active Member
    Reputation
    69
    Join Date
    Feb 2007
    Posts
    386
    Thanks G/R
    6/2
    Trade Feedback
    1 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The "WTF" code as you call it.. Calculates how much damage the group/raid is taking, if it's beyond the threshold you set as above in the variable, it'll cast the corresponding spell.

  4. #19
    cdmichaelb's Avatar Contributor CoreCoins Purchaser
    Reputation
    119
    Join Date
    Jan 2011
    Posts
    368
    Thanks G/R
    21/5
    Trade Feedback
    7 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Sikas View Post
    The "WTF" code as you call it.. Calculates how much damage the group/raid is taking, if it's beyond the threshold you set as above in the variable, it'll cast the corresponding spell.
    Is it wrong then? d=0 and n=0 n>(npe*0.2) will always be false .... d/n>5000 0/0>5000 duh?? no d/n isn't greater than 5000....


    edit: also... d/n are never defined anywhere... except d is used for a buff array for casting beacon on focus.
    Last edited by cdmichaelb; 04-20-2011 at 08:40 PM.

Page 2 of 2 FirstFirst 12

Similar Threads

  1. paying for a good private lua macro for holy paladin and ret paladin pvp
    By Speedracer22 in forum WoW UI, Macros and Talent Specs
    Replies: 0
    Last Post: 03-25-2012, 02:00 PM
  2. [LUA/macro] Another "need help" thread, easy rep.
    By Ssateneth in forum WoW UI, Macros and Talent Specs
    Replies: 15
    Last Post: 11-26-2010, 06:04 AM
  3. [Class] Holy Paladin Pve Guide(updated version)
    By JimmyTheGoat in forum World of Warcraft Guides
    Replies: 4
    Last Post: 06-15-2010, 06:57 PM
  4. Holy Paladin PvE Guide, updated 3.3
    By Noblebeastx in forum WoW UI, Macros and Talent Specs
    Replies: 1
    Last Post: 05-26-2010, 03:29 AM
  5. [Urgent!!] Holy Paladin pros' help needed!
    By Illidan_000 in forum World of Warcraft General
    Replies: 4
    Last Post: 08-09-2009, 09:28 PM
All times are GMT -5. The time now is 10:52 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search