|
Post by Toversnol on Jul 20, 2007 19:19:16 GMT 1
Making the Macro’s Naming Codes:#show Fireball #showtooltip FireballWith this code you can show a spells cooldown and spell info when mouse over the macroReset Function:reset=6Number of seconds until the macro resets.Starting Codes for an Action:/castsequence Fireball, FrostboltCast a series of spells/cast FireballCast a spell/castrandom Fireball, FrostboltCast a random spell of the macro/stopcastingCancel the casting of all spells/use Insignia of the HordeUse an item. (example: Trinkets)/userandom Insignia of the Horde, Medallion of the hordeUse a random item of the macro/click PetActionButton5Use your pet skill/equip Fishing HatChange equipment/weapons/equipslotChange equipment/weapons <I don’t know how this one works..>/cancelaura Ice BlockRemove a friendly buff/cancelform Ghost WolfRemove your form/dismountRemove your mountTargeting Functions in the Macro[target=target,help,nodead]Assist your target if it is not dead[target=targettarget,help,nodead]Assist the target of your target[target=player]Target is a player[target=focus]your target is the target that you put focus on[target=focus, nodead, exists]your target is the target that you put focus on. If it exist or not is dead[target=pettarget, exists]Your target is your pet, if it exists[nocombat]If not in combat this sentence of the macro will be used[nopet]If there is no pet this sentence in the macro will be used.[nobutton:2]If you don’t use the left mouse button, this part of the macro will be used.[nochanneling:Arcane Missiles]This makes a arcane missile button spammable[button:2]Left mouse button on the macro and you use this part[modifier:alt] [modifier:shift] [modifier:ctrl]If you hold alt, shift or ctrl you will use the macro after this code%T = Target The code for naming your target%F = Focus Shorter version for focusMacro ExamplesPolymorph: Pig + Focus #Showtooltip Polymorph: Pig /cast [modifier:alt, target=focus] Polymorph; Polymorph /focus [nomodifier:alt]Multiple Portals /cast [modifier:shift] Portal: Silvermoon; [modifier:alt] Portal: Undercity; [modifier:ctrl] Portal: Thunder Bluff; Portal: OrgrimmarAttacking Water Elemental /cast [nopet] Summon Water Elemental /stopmacro [target=pettarget, exists] /petattack *This Thread is gonna be edited, not finished yet. but its a start to make macros!*
|
|
|
Post by Toversnol on Dec 30, 2007 22:37:38 GMT 1
Targeting:
/targetenemy /targetfriend /targetparty /targetraid /targetlasttarget /targetlastenemy /assist [name] - Assist your target or the named unit if specified
Using Items:
/use /equip /equipslot /userandom , , item3, …
Examples of /equip and /use:
/equip <itemname> /equip <bagid> <bagslot> /equipslot <slot> <itemname> /use <itemname> /use <slot> /use <bagid> <bagslot> /userandom <item1>, <item2>, <item3> will attempt to use a randomly selected one of the specified items
Casting:
/stopcasting /cast [option] /stopmacro [option] /castrandom , , … /castsequence [reset=N/target/combat/shift/alt/ctrl] , , …
Sequenced Casting
* A new command /castsequence reset=N/target/combat/shift/alt/ctrl spell1, spell2, spell3 * The reset line can specify a number of seconds after which a sequence resets, or if it should reset on target change or leaving combat. * The sequence tracks the 'next' spell in the sequence until it resets, the next spell only advances on a successful cast. * You can specify a conditional at the start of the command before the reset to filter whether the sequence is used (You cannot use per-spell conditionals) * You can specify items and stances as well as spells
Action Bars:
/changeactionbar /swapactionbar
Attacking:
/startattack [unit] /stopattack
Buffs/Auras:
/cancelaura [Stormpike Battle Charger]
OPTIONS
If multiple options are provided for an action, they must all be met before the action will happen. The options supported are as follows:
* target=unit - Run the command and perform tests on the specified unit (only applicable to spell casting or item use). You can specify 'none' as a target unit to act as if you have no target. * help/harm - Choose depending on whether target is assistable or attackable * combat - Choose depending on whether you're in combat or not * stance or stance:# - Choose depending on your stance/shapeshift ("stance" alone matches any stance) * stealth - Choose depending on whether you are stealthed * mounted - Choose depending on whether you are mounted * swimming - Choose depending on whether you are swimming * flying - Choose depending on whether you are flying * indoors - Choose depending on whether you are indoors * outdoors - Choose depending on whether you are outdoors * modifier or modifier:shift|ctrl|alt - Choose depending on any modifier keys you're holding at the time the macro runs * equipped:|| - Choose if you have the specific item type equipped * actionbar: - Choose if a specific actionbar is shown * button:Z - Choose if the specified button is held down * pet:| - Choose if your current active pet has the specified name or family (e.g. pet:bear/wolf) * channeling or channeling:spell - Choose if you are channeling (possibly a specific spell) * exists - Choose if the target exists * dead - Choose if the target is dead
For stance and modifier you can list multiple matching values separated by the / character for the option to be true if ANY of them are true. For example modifier:shift/ctrl matches if shift or control is held down. Any option can be prefixed with 'no' to select if it does NOT match. For example [nocombat]
# and - are comment characters in macros A macro that starts with "# show or # showtooltip <item or spell>" will show feedback for that item or spell. A macro that starts with "# show none" will show no feedback. Otherwise the first /cast, /randomcast, /castsequence, /use, or /random use command will be used to show feedback for the macro. Castsequence is special in that it overrides the "#show" parameter. This is intentional, as most people want the current spell to show up instead of what is listed on "#show. --------------------
macros within macros?
/click <button name>
You can find a button name by hovering your mouse over a button and entering this into chat:
/script message(GetMouseFocus():GetName())
----------------
Setting raid target icons
SetRaidTargetIcon("target", 1); -- Star SetRaidTargetIcon("target", 2); -- Circle SetRaidTargetIcon("target", 3); -- Diamond SetRaidTargetIcon("target", 4); -- Triangle SetRaidTargetIcon("target", 5); -- Moon SetRaidTargetIcon("target", 6); -- Square SetRaidTargetIcon("target", 7); -- Cross SetRaidTargetIcon("target", 8); -- Skull SetRaidTargetIcon("target", 0); -- Remove RaidIcon
are the units
if you just want to put the skull (8) on one target use:
/script if (GetRaidTargetIndex("target")~=8) then SetRaidTargetIcon("target", 8); end
if you want to target a group - one use each target:
/script if not lastraidn then lastraidn = 1; end SetRaidTarget("target", lastraidn); if lastraidn == 8 then lastraidn = 1; else lastraidn = lastraidn + 1; end
|
|
|
Post by Toversnol on Jul 22, 2009 13:32:38 GMT 1
Macro Guide
NO macro can cast spells based on: BUFFS, DEBUFFS, COOLDOWNS, or TARGET DISTANCE
NO macro can cast spells based on: HEALTH, MANA, RAGE, ENERGY, or COMBO POINTS
Any failed cast attempt stops the macro from casting any further spells
* Except for spells that do not invoke the Global Cooldown (GCD)
/cast Spell - casts Spell on your target
* Spells will automatically reduce rank if the target is too low a level * Spells written without "(Rank N)" will automatically cast the highest rank you know * NOTE: Spells with parentheses as part of their name require extra "()" after, e.g.:
/cast Faerie Fire (Feral)() or /cast Mangle (Bear)()
/cast [condition] Spell - casts Spell when condition is true. condition can be:
* help/harm - Choose depending on whether target is assistable or attackable * combat - Choose depending on whether you're in combat * stance or stance:# - Choose depending on your stance/shapeshift ("stance" alone matches any stance)
stance:1 is (Dire) Bear Form stance:2 is Aquatic Form stance:3 is Cat Form stance:4 is Travel Form stance:5 is Moonkin Form or Tree of Life (if talent points spent), or Flight Form stance:6 is Flight Form if you already have Moonkin Form or Tree of Life NOTE: Numbers may be different if you are missing earlier forms
* stealth - Choose depending on whether you are stealthed * mounted - Choose depending on whether you are mounted * swimming - Choose depending on whether you are swimming * flying - Choose depending on whether you are flying * flyable - Choose depending on whether you are able to use Flight Form / flying mount * indoors - Choose depending on whether you are indoors * outdoors - Choose depending on whether you are outdoors * modifier or modifier:shift/ctrl/alt - Choose depending on any modifier keys you're holding at the time the macro runs * equipped:InvSlot#|ItemClass|ItemSubclass - Choose if you have the specific item type equipped * actionbar:Bar# - Choose if a specific actionbar is shown * button:Z - Choose if the specified button is held down * pet:Name|Family - Choose if your current active pet has the specified name or family (e.g. pet:bear/wolf) * channeling or channeling:Spell - Choose if you are channeling (possibly a specific spell) * exists - Choose if the target exists * dead - Choose if the target is dead * party - Choose if target is in your party * raid - Choose if target is in your raid * group:party/raid - Choose if you are in a party or raid * Any condition can be prefixed with "no" to select if it does NOT match
/cast [target=unit] Spell - casts Spell on unit without changing your target. unit can be:
* player (yourself), target, focus, mouseover, pet, PlayerName, or none * target=unit is not actually a condition * target=unit forces other conditions to evaluate using unit instead of the real target * NOTE: target=none will function as if you had no unit selected, giving you the "glowing hand" selector (unless you have enabled auto self-cast?) * Any unit can be followed by "target" to designate that unit's target, e.g.:
targettarget, pettarget, or PlayerName-target (note extra "-")
/cast [condition1a, condition1b] Spell1; [condition2a] [condition2b] Spell2; Spell3 - casts Spell1 when both condition1a and condition1b are true, or Spell2 when either condition2a or condition2b is true, and Spell3 anytime else, e.g.:
* /cast [stealth] Pounce; [nocombat, nostealth] Prowl; [modifier:ctrl] Rip; Mangle (Cat)() * Separate multiple conditions with " , " (comma) * Separate multiple casting choices with " ; " (semicolon)
/castsequence reset=event Spell1, Spell2, Spell3, etc. - casts Spell1 then Spell2 on next click, then Spell3, and so forth
* castsequence will not advance to the next spell until the current spell is successfully cast * The sequence maintains state (the current spell awaiting cast) until it is reset, even if a requisite condition becomes false * The sequence always resets after casting the final spell, and also when event occurs ("reset=event" is optional)
But you can prevent the sequence from automatically resetting at the end by ending with a spell that will always fail, or by repeating the last spell several times
* event can be: N (seconds), target (when target changes), combat, shift, alt, and/or ctr * Separate multiple reset events with " / " * Supports spells and items and slot numbers and bag slot numbers * NOTE: Spells with parentheses as part of their name ALWAYS require "(Rank N)", e.g.:
/castsequence Faerie Fire (Feral)(Rank 4), Maul, Mangle (Bear)(Rank 3), Swipe NOT: /castsequence Faerie Fire (Feral)()
/cancelaura [condition] Buff - cancels a Buff as if it were right-clicked, e.g.:
* /cancelaura [stance:2] Aquatic Form; [stance:3] Cat Form; [stance:4] Travel Form * The above macro cancels Aquatic, Cat, and Travel Form, returning you to caster form * It does nothing while in Bear Form because "[stance:1] Dire Bear Form;" is missing * With /cast [nostance] Dire Bear Form, the macro shifts you into Bear Form, but never out * This shifting behavior is known as "sticky"
/cancelform [condition] - cancels any form you are in, subject to the condition, e.g.:
* /cancelform [nostance:1] - cancels every form except for Bear Form (same as the above /cancelaura line)
#show and #showtooltip - display cooldown (and tooltip) of next Spell or Item or Inventory Slot# or Backpack Slot# over the macro's icon
* The question mark icon [?] will copy the spell's original graphic * The question mark icon [?] will dynamically update with each spell in a castsequence or change in condition (NEW) * Conditions can also be used directly in the #show and #showtooltip lines, e.g.:
#show [nostance] 13; [stance:3, nocombat] Prowl
/focus unit - allows you to "store" a target until you clear the focus (with /clearfocus), which can be targetted at any time (with /target focus, or [target=focus])
Other "slash commands" include:
* Targeting: /targetlasttarget, /cleartarget, /focus, /clearfocus * Target Cycling: /targetenemy, /targetfriend, /targetparty, /targetraid - All work using the TargetNearest* API's and enemy/friend may only be called once per macro. An optional argument of '1' can be used to reverse direction. * Items and equipment: /use ItemName, /use Slot#, /use BagID# BagSlot#, /equip ItemName or ItemID#, /equipslot Slot# ItemName, /userandom Item1, Item2, Item3 will attempt to use a randomly selected one of the specified items * Pet control: /petattack, /petfollow, /petstay, /petpassive, /petdefensive, /petaggressive, /petautocaston Spell, /petautocastoff Spell * Casting: /stopcasting will cancel the spell that is currently being cast, /castrandom Spell1, Spell2, Spell3 will attempt to cast a randomly selected one of the specified spells * Action bar: /changeactionbar Bar# and /swapactionbar Bar1# Bar2# * Attacking: /startattack unit ("unit" is optional), /stopattack * Buffs/Auras: /cancelaura name - cancels an aura as if it were right clicked * Buttons: /click ButtonName MouseButton# ("MouseButton#" is optional) * Macros: /stopmacro * Dismounting: /dismount - note that the default UI now automatically dismounts you upon casting
Tips to shrink macro length to fit within 255 character limit
* Remove spaces around any punctuation (" [ ] = , ; ") * ItemName only needs enough text to make the item unique
|
|