Portal   Forum   Members   Market   Gallery   Events

macro: automatic trinkets when firing frostbolt

Discussion in 'Game Help' started by Jakeman, Aug 23, 2006.

  1. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    If you have two juice trinkets equipped (or even one), then manually activating them can be a pain. This macro checks cooldowns on both trinket slots and activates the first one that is ready. Then it fires frostbolt.

    Code:
    /script if (GetInventoryItemCooldown("player", 13) == 0) then UseInventoryItem(13) end;
    /script if (GetInventoryItemCooldown("player", 14) == 0) then UseInventoryItem(14) end;
    /cast Frostbolt(Rank 11);
    
    Now you can just spam this macro in place of your normal frostbolt. The damage bonus from your trinkets will be passive.
     
  2. MisterHalleck

    MisterHalleck Peasant

    Joined:
    Aug 27, 2000
    Messages:
    2,746
    Likes Received:
    15
    Market Rating:
    0
    Cool.

    Is the macro/scripting language documented at all? I never saw any evidence of it, but then again I probably didn't know where to look.
     
  3. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    Just search google for stuff like "wow macro cooldown." You usually get referred to wowwiki. I usually look for specific functions for what I want, then plug them into examples I find.
     
  4. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    I optimized this macro:


    /script if (GetInventoryItemCooldown("player", 13) == 0) then UseInventoryItem(13) SpellStopCasting() else if (GetInventoryItemCooldown("player", 14) == 0) then UseInventoryItem(14) SpellStopCasting() end end CastSpellByName("Frostbolt");

    I made it one big command instead of 3 smaller ones. I also added SpellStopCasting() after each trinket fire. This eliminated a problem with frostbolt not firing after a trinket activation with one press of the macro (required spamming it). These changes also eliminated "another action is in progress" errors when a trinket was activated.
     
  5. Lurk

    Lurk Peasant and Donator

    Joined:
    Jul 19, 2000
    Messages:
    2,586
    Likes Received:
    47
    Market Rating:
    0
    Does that automatically pick max rank?
     
  6. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    Yes, I remember reading that in some old patch notes. I have also tested this macro and it is definitely using my rank 11.
     
  7. Lurk

    Lurk Peasant and Donator

    Joined:
    Jul 19, 2000
    Messages:
    2,586
    Likes Received:
    47
    Market Rating:
    0
    Shibby. I may use this for my ToEP.
     
  8. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    Hmm, this macro still generates some errors when a frostbolt is currently firing and a trinket is cooled and you are spamming the macro. Then it tries to fire the trinket during a cast which obviously generates an error for each click until the cast is done. It only happens right before a trinket fires, but it still annoys me.

    I can't find a function to check if there is currently an action in progress.
     
  9. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    The macro forum hasn't been helpful. Apparently there is no way to fix this problem which is annoying as hell because it means I still have to pay attention to the cooldowns and micromanage.
     
  10. Lurk

    Lurk Peasant and Donator

    Joined:
    Jul 19, 2000
    Messages:
    2,586
    Likes Received:
    47
    Market Rating:
    0
    Lrn2trinket :p

    I keep mine on my hotbar so I can see the cooldown. The actual use of it is bound to a mouse button.
     
  11. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    New for 2.0:

    Code:
    /use Zandalarian Hero Charm
    /stopcasting
    /use Talisman of Ephemeral Power
    /stopcasting
    /cast Frostbolt
    
    Note that you can't "use" a specific slot. You have to name the item. This means you can't swap out trinkets without modifying the macro or adding all trinket names similar to the mount macro:

    http://www.mscclan.com/forum/showthread.php?p=134833#post134833

    Due to changes in 2.0, this macro now has the following problems:

    1) No cooldown checks. This means that you will get errors every time you click the macro.

    2) Also no condition for "spellstopcasting". This means the macro is not spamable. If you spam it then you will continually interrupt your frostbolt because of /stopcasting. This means you have to put the macro on one key for initial "one time" use in activating trinkets, then put a regular frostbolt on another key for spam action.

    thx Blizzard
     
  12. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    My lastest version:

    Code:
    # show Frostbolt
    /script UIErrorsFrame:Hide();
    /use 13
    /use 14
    /stopcasting
    /cast Frostbolt
    /script UIErrorsFrame:Clear();
    /script UIErrorsFrame:Show();
    
    This fires both trinket slots and suppresses text errors but not sound errors. Not spammable due to /stopcasting. So you need to have one button to fire at the start and another button to spam the regular nuke.
     
  13. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    My latest experiment:

    Code:
    # show Frostbolt
    /script UIErrorsFrame:Hide()
    /use [modifier:shift] Talisman of Ephemeral Power
    /use [modifier:shift] Vengeance of the Illidari
    /stopcasting [modifier:shift]
    /cast Frostbolt
    /script UIErrorsFrame:Clear()
    /script UIErrorsFrame:Show()
    
    This makes it so a normal activation acts just like a normal frostbolt (spamable, no errors), while a shift modifier activates the trinkets and fires (like before). This frees up one spot on the hotbar where I had my normal frostbolt.

    Unfortunately the macro system seems to have a bug that prevents this from working:


    Code:
    # show Frostbolt
    /script UIErrorsFrame:Hide()
    /use [modifier:shift] [color=red]13[/color]
    /use [modifier:shift] [color=red]14[/color]
    /stopcasting [modifier:shift]
    /cast Frostbolt
    /script UIErrorsFrame:Clear()
    /script UIErrorsFrame:Show()
    
    So once again you have to manually specify your trinket names. I have reported this bug to the GMs.
     
  14. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
  15. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    Removing the show / hide error frame appears to have no affect on the result. Just having the clear at the end works equally well to supress errors. So here is a simpler version that does the same thing:

    Code:
    # show Frostbolt
    /use [modifier:shift] Xi'ri's Gift
    /use [modifier:shift] Vengeance of the Illidari
    /stopcasting [modifier:shift]
    /cast Frostbolt
    /script UIErrorsFrame:Clear()
    
    I have modified this for my own personal use, where it will automatically dismount me if I am mounted:

    Code:
    # show Frostbolt
    /use [mounted] 0 4
    /use [mounted] 0 8
    /use [modifier:shift] Xi'ri's Gift
    /use [modifier:shift] Vengeance of the Illidari
    /stopcasting [modifier:shift]
    /cast Frostbolt
    /script UIErrorsFrame:Clear()
    
    You will see that is uses the 4th and 8th slots of my first bag (both of my mounts) if I am currently mounted. That way I can simply start spamming frostbolt to dismount and attack instead of right clicking the mount manually. This is very helpful when I am farming a large area that requires me to constantly mount and dismount to get places fast.
     
  16. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    Here is the latest version of this macro for 2.1 (currently PTR):

    Code:
    # show Frostbolt
    /dismount [mounted]
    /use [modifier:shift] 13
    /cast Frostbolt
    /script UIErrorsFrame:Clear()
    
    Blizzard really cleaned things up:

    1) They fixed the inconsistency where you could not specify a generic item slot with a shift modifier, so this macro is now generalized again so you don't have to manually specify the trinket name.

    2) They added a dismount command, so the addition I made where it dismounts you upon firing is now generalized and does not have to manually specify mount item locations.

    3) They have apparently improved the synchronization of sequential commands such that "stopcasting" is no longer required as a buffer. As a side effect of this, the dismount + fire (or dismount + trinket + fire) is now performed in only one click instead of two making for quick transitions.
     
  17. Elbereth

    Elbereth MSC Commander and Donator

    Joined:
    Jun 17, 2000
    Messages:
    3,356
    Likes Received:
    14
    Market Rating:
    0
  18. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    Latest version for 3.0:

    /dismount [mounted]
    /use [flyable, noharm] [flyable, dead] Swift Blue Gryphon; [noharm] [dead] Amani War Bear
    /stopmacro [noharm] [dead]
    /use [modifier:shift] 13
    /cast [modifier:shift] Icy Veins
    /cast Frostbolt

    1) I removed the # show Frostbolt comment since it is unnecessary if you use the "?" macro icon with the macro. The "?" icon makes it show whatever tooltip will be fired given the conditions in the macro.

    2) I removed the line at the end to clear the error frame. 3.0 now has smart error reporting that doesn't spam you with errors so it's not an annoyance anymore.

    3) I added a new command to use your mount when appropriate (not targetting a hostile, or the hostile is dead). That makes this an all-in-one hotkey for nuking, mounting, dismounting, and juicing (shift + click). It doesn't include an item swap for a riding crop, but Blizzard says that any new mount speed items will be passives and won't require a swap.

    I have been using this on the PTR and it's super convenient since it covers all common actions involved in killing and moving. And it's always just a regular button push unless you want to activate your trinket and Icy Veins.
     
  19. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,756
    Likes Received:
    27
    Market Rating:
    16
    Actually it works in 2.x too. There is nothing new to 3.0 except that you will probably want to keep the error frame clearing in 2.x:

    /dismount [mounted]
    /use [flyable, noharm] [flyable, dead] Swift Blue Gryphon; [noharm] [dead] Amani War Bear
    /stopmacro [noharm] [dead]
    /use [modifier:shift] 13
    /cast [modifier:shift] Icy Veins
    /cast Frostbolt
    /script UIErrorsFrame:Clear()
     
  20. Lurk

    Lurk Peasant and Donator

    Joined:
    Jul 19, 2000
    Messages:
    2,586
    Likes Received:
    47
    Market Rating:
    0
    Auto-dismount on cast is an interface option, so you could probably dispense with the dismount command if you really wanted to. Six of one, half dozen of the other.
     

Hitometer: 53,596,040 since 1995