ButteredToast 0 Report post Posted January 5, 2017 Heya, Basically i'm playing with a pally/priest and wanted to make a macro for the priest so that it will apply SW:P to the target only if it isnt affected, and if it already is then it'll cast smite, I found this after googling and added abit to make it what i wanted but its throwing errors. Any help appreciated /Script if UnitIsFriend("player", "target") then TargetUnit("targettarget") end; if not buffed("Shadow Word: Pain", 'target') then cast("Shadow Word: Pain");else c("Smite(Rank 1)"); end; TargetLastTarget() 0 Share this post Link to post Share on other sites
Ike 20 Report post Posted January 5, 2017 Get this addon and use the following macro: /cast [nobuff:Shadow_Word @target] Shadow Word: Pain; Smite While the addon might be a bit overkill for this one macro, it enables you to write many more advanced macros like this one without having to know a single thing about Lua! 0 Share this post Link to post Share on other sites
ButteredToast 0 Report post Posted January 5, 2017 Fantastic, Thank you =) 0 Share this post Link to post Share on other sites
ButteredToast 0 Report post Posted January 5, 2017 Sorry to continue on this, but i was trying to get one to work like this, So if PW:S isnt up it casts it, but if it is then it heals, however i need a CD for the PW:S any idea? /cast [nobuff:Power_Word @target] Power Word: Shield; Lesser Heal 0 Share this post Link to post Share on other sites
Ike 20 Report post Posted January 5, 2017 (edited) From the addon's Wiki page: Quote Gray button fix: In order to fix the range and cooldown check (gray buttons), you have to write this line at the top of each macro: /script if nil then CastSpellByName("SPELLNAME"); end Make sure to replace SPELLNAME with the actual name of your spell. Example: /script if nil then CastSpellByName("Chain Heal"); end /cast [@target help mod:alt] Chain Heal; Chain Heal(Rank 1) Note There is currently no way to make this work for different spells depending on conditionals Example: /script if nil then CastSpellByName("Chain Heal"); end /cast [@target help] Chain Heal; Frost Shock This will only activate the range and cooldown check for Chain Heal and not check Frost Shock at all! This should answer your question! :) Edited January 5, 2017 by Ike formatting 0 Share this post Link to post Share on other sites