Navigation menu
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
Namespaces
WoW
Talk
English
Views
Read
Edit
History
More
Search
Navigation
Home
Random page
Help using wiki
Editions
for WoW
for WildStar
for Solar2D
Documentation
for WoW
for WildStar
Reference
WoW
⦁ FrameXML
⦁ AddOns
⦁ API
⦁ WoW Lua
WildStar
⦁ AddOns
⦁ API
⦁ WildStar Lua
Engine
Tools
What links here
Related changes
Special pages
Page information
Site
Recent Changes
Editing
WoW:MACRO cast
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Examples == Revive a pet if it is out and dead, call the pet if it is not out, or mend the pet if it is out and alive /cast [target=pet,dead] Revive Pet; [nopet] Call Pet; Mend Pet Cast Flash Heal on target; but cast on yourself if your target is hostile, or dead, or you have no target, or if right-click. /cast [target=self, btn:2][target=focus, help, nodead, exists][target=player] Flash Heal === Let's analyze === [target=self, btn:2] The script sets the target of the spell to yourself, and checks to see if you right-clicked. If you did, it skips the next two option sets and casts Flash Heal, keeping the '''target''' it set (you). If you didn't r-click, it checks the next option set: [target=focus, help, nodead, exists] It sets the target of the spell to whatever your current target (focus) is. If the target is friendly ('''help''') AND it's alive ('''nodead''') AND you actually have something selected ('''exists'''), then it skips the next option set and casts Flash Heal, again keeping the target it set (focus). Otherwise, if any of those conditions are not true, it checks the next option set: [target=player] Since there are no conditions in this set, it just casts Flash Heal, again keeping the target it just set (you).
Summary:
Please note that all contributions to AddOn Studio are considered to be released under the Creative Commons Attribution-NonCommercial-ShareAlike (see
AddOn Studio Wiki:Copyrights
for details).
Submissions must be written by you, or copied from a public domain or similar free resource (see
AddOn Studio Wiki:Copyrights
for details).
Cancel
Editing help
(opens in new window)