Trying to get Moonfire to cast @mouseover even if i have a target or if no mouseover it casts on my target. I can get it to fire off on my mouseover target, but if I have a mob targeted with no mouseover it wont fire. I get the message you have no target, yet I clearly do and its in range also. If I remove my @mouseover and have only @target it will fire on my target.
#showtooltip
/cast [@mouseover][@target] Moonfire
This is my macro atm. What am I doing wrong?
So it seems to work atm with adding exists to the mouseover section.
I’m not entirely sure that you can meet the second condition with two commands in the same line. If mouseover command is enabled, from interface or through a macro, it will always have higher priority than current target and if you already have one selected but you aren’t mouseovering anything, your casts should by default go towards the current target.
After testing myself, it seems like they’ve changed how some commands work. Try like this.
/cast [@mouseover,exists][@target] Moonfire
It would be much simpler to enable mouseover casting via game menu but understandably you might prefer to have more control over your individual spells.
Homeopathy is along the right line of thinking…
The macro will only move on to try the second conditional [@Target] if the first conditional [@Mouseover] is resolved as FALSE.
The @mouseover condition is always considered TRUE (even if your mouse cursor isn’t over a unit or unitframe). Without an additional clause, your macro will always resolve with the first conditional and try to cast Moonfire wherever your mouse cursor is. This is causing the error message stating you have no target (even if you have a target).
When you add “exists” to the first conditional then it will only resolve as TRUE if both conditions are considered TRUE. We know @mouseover is always considered TRUE but “exists” is only considered TRUE if you are moused over an existing unit/unitframe.
If you are not moused over a unit/unitframe the conditional [@mouseover, exists] is resolved as FALSE and the macro moves on to try the next conditional [@target]
I would suggest avoiding “exists” where possible. There is usually a more precise condition and examples include: “harm”, “help”, “dead”, and “nodead”. All of these conditions imply that a unit exists but can avoid your macros behaving unexpectedly.
In your case, I would suggest replacing “exist” with “harm” and “nodead”.
/cast [@mouseover,harm,nodead][@target] Moonfire
A benefit to using the above…
If you accidently mouseover a dead or friendly unit, “exists” would just throw an error message. Speaking from experience, this happens more often than you’d think. Other players have a habbit of running in front of your mouse cursor. By replacing “exists” with “harm” and “nodead”, Moonfire will still cast on your target.
You could also drop the @target for efficiency since Moonfire will only cast on your target by default:
/cast [@mouseover,harm,nodead][] Moonfire
But then leaving the @target in the macro may make it easier to read in the future
Thank you both very much, I will change the exists to ,harm,nodead.
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.