Download
(7Kb)
Download
Updated: 12-03-06 11:41 PM
Updated:12-03-06 11:41 PM
Created:unknown
Downloads:43,475
Favorites:71
MD5:

AfterCast  Popular! (More than 5000 hits)

Version: v1.1-20000
by: Iriel [More]

AfterCast - Perform action after a cast
---------------------------------------------------------------------------
This is a fairly simple addon for performing actions based on the success or failure of a cast. Usage is as follows

/aftercast /smile
/aftercast +fail /cry
/cast Frostbolt(Rank 2)

If the spell succeeds then you'll smile, if it fails, then you'll
cry. If it is interrupted then nothing will happen.

Events you can use are:

+done At the end of successful casting (Default if no event given)
+fail If the spell fails
+interrupt If the spell is interrupted
+start When spell starts casting (Fires before done for instant spells)

Aftercasts apply to the next spell which occurs, and then is reset, you can set up one of each event before each cast.

These functions can also be gotten at via lua functions

AfterCast(doneAction, failAction);
Shortcut to set up the 2 most common actions, either can be nil.

AfterCastOn(event, action)
Set up a specific action (use without the +, so "done", "fail", etc)

AfterCastReason([clearFlag])
Return the stop reason ("done"/"interrupt"/"fail") for the last cast (nil if none have stopped since the last clear).. if clearFlag is present and true then resets status after return.

Optional Files (0)


Post A Reply Comment Options
Unread 07-26-11, 01:46 AM  
runescaper11
A Kobold Labourer

Forum posts: 0
File comments: 2
Uploads: 0
How does it work?

hi Iriel,

i downloaded this macro so that my hunter could cast a continued sequence of steady shot to generate focus. i tried this with the /aftercast command but it hasn't worked. here is the macro:

#showtooltip
/cast Steady Shot
/aftercast /Steady shot
/aftercast /Steady shot
/aftercast /Steady shot
...

how will i get this to work? did i get the code wrong or does it just not like repetitiveness? also is says: Unexpected event 'UNIT_SPELLCAST_SENT in sent'

thanks in advance
Last edited by runescaper11 : 07-26-11 at 01:48 AM.
Report comment to moderator  
Reply With Quote
Unread 07-26-11, 01:58 AM  
Nibelheim
local roygbi-
 
Nibelheim's Avatar
AddOn Author - Click to view AddOns

Forum posts: 1600
File comments: 2305
Uploads: 21
Re: How does it work?

Originally posted by runescaper11
hi Iriel,

i downloaded this macro so that my hunter could cast a continued sequence of steady shot to generate focus. i tried this with the /aftercast command but it hasn't worked. here is the macro:

#showtooltip
/cast Steady Shot
/aftercast /Steady shot
/aftercast /Steady shot
/aftercast /Steady shot
...

how will i get this to work? did i get the code wrong or does it just not like repetitiveness? also is says: Unexpected event 'UNIT_SPELLCAST_SENT in sent'

thanks in advance
Aftercast doesn't really work that way. And, I believe what you're describing is impossible to achieve, as Blizzard has designed the UI/addons/macros to be "one input = one action".
Report comment to moderator  
Reply With Quote
Unread 08-08-12, 11:58 AM  
Antares1986
A Kobold Labourer

Forum posts: 0
File comments: 2
Uploads: 0
Will it work for Cataclysm ? 4.0.6 for example ?
This addon is really useful, I was trying to do simple macro but was tired from accidental spamming when spell actually fails.
If it doesn't work in Cataclysm, can you write a version for it ?
Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump: