WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   Macro Help (https://www.wowinterface.com/forums/forumdisplay.php?f=140)
-   -   Power Word: Shield with a twist (https://www.wowinterface.com/forums/showthread.php?t=38746)

19logan91 02-05-11 12:22 AM

Power Word: Shield with a twist
 
ok so my actionbar's are macro'd like crazy. But there is still one important (to me) macro i cant figure out. here's what i want it to do.

I would press the macro, it would cast Power word shield on myself, but when i press it again it casts on my target. if i have no target or if my target has Weakened Soul, or if my target is an enemy i want the glowing hand to pop up so i can select a target.

i think it would look someting like this
Code:

#showtooltip
/castsequence [target=player] Power Word: Shield, Power Word: Shield

thats all i've got >.< cause this one really confuses me lol.

Akkorian 02-05-11 12:27 AM

Hi Logan,

Unfortunately you can’t have different targets for different spells in a cast sequence. The closest you could get to that would be to have the macro cast Power Word: Shield on yourself when you right-clicked it, or held a modifier key like Shift or Alt.

/cast [mod:alt, @player] [btn:2, @player] [] Power Word: Shield

The empty brackets [] are important because they tell WoW to cast the spell “normally” if neither of the first two conditions are met.

19logan91 02-05-11 12:38 AM

the only problem is im not going to be pressing it with my mouse its on an actionbar slot that is keybound. i think i made it sound over complicated.
how about it casts on me then just casts normally? so maybe a sequence that first it casts on me and second it trys on whatever im targeting / glowing hand if nothings targeted

19logan91 02-05-11 12:43 AM

maybe even if its possible. just to try to cast it on me, if not target/glowinghand

Akkorian 02-05-11 12:49 AM

There’s no way for a macro to do what you’re describing. You can’t cast a different spell each time you press the button without using a cast sequence, and you can’t switch targets in the middle of a cast sequence. Macros also can’t tell whether you have a spell on the cursor, or pick a target for the glowing hand. Blizzard wrote the macro system on purpose so that it’s not possible to have a macro (or addon) that makes decisions like that on the fly. Even though what you’re describing is probably something Blizzard would be okay with, there’s just no way for them to make it possible without also making it possible for macros to do lots of other things that Blizzard isn’t okay with.

With the macro I posted before, you can also self-cast by holding down the Alt key while pressing the key binding for the button it’s on. You can change the Alt to Shift or Ctrl if you like, and remove the btn:2 part if you know you’ll never click it.

Akkorian 02-05-11 12:50 AM

Quote:

Originally Posted by 19logan91 (Post 228700)
maybe even if its possible. just to try to cast it on me, if not target/glowinghand

Macros can’t check for a spell on the cursor (the glowing hand). You could do this:

/cast [help] [@player] Power Word: Shield

That would cast it on you unless you had a friendly target.

19logan91 02-05-11 01:18 AM

i tried it but it wasn't quite working right. but what seems to be working ok is
Code:

/cast [help]Power Word: Shield
/stopmacro [help]
/cast [@player] Power Word: Shield

it just casts at my target but it auto casts on me otherwise. no Spell on the Cursor but its better than it was

ravagernl 02-05-11 09:02 AM

Quote:

Originally Posted by 19logan91 (Post 228704)
i tried it but it wasn't quite working right. but what seems to be working ok is
Code:

/cast [help]Power Word: Shield
/stopmacro [help]
/cast [@player] Power Word: Shield

it just casts at my target but it auto casts on me otherwise. no Spell on the Cursor but its better than it was

Which is the same as
Code:

/cast [help][@player]Power Word: Shield
You can even add a mouseover target and more if you want to:
Code:

/cast [@mouseover,help][@mouseovertarget,help][help][@targettarget,help][@player,mod][]Power World: Shield
  1. Cast on friendly unit under your mouse, or
  2. Cast on the target of your mouseover unit if mouseovertarget is friendly, or
  3. Cast on the target if the target is friendly
  4. Cast on the target of your target if it is friendly (when you are targetting a boss for example and you want to shield the tank)
  5. Cast on yourself if you are holding a modifier key, such as ctrl, alt or shift
  6. If all else fails, just cast Power Word: Shield in the normal behavior. This also makes sure the actionbar shows the correct spell icon when none of the conditions match, as [] will always match.
This type of macro can be used for all your healing/buff spells :)


All times are GMT -6. The time now is 07:39 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI