WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   General Authoring Discussion (https://www.wowinterface.com/forums/forumdisplay.php?f=20)
-   -   announce for casts in progress on the player (https://www.wowinterface.com/forums/showthread.php?t=47526)

launchcodemexico 08-07-13 08:03 PM

announce for casts in progress on the player
 
i want to write an addon that performs the following:

if ([Ability1, Ability2,... AbilityX] is being cast upon you from any NPC's or players) -> announce

for example, if a warlock somewhere/anywhere has targeted you and has begun to cast Chaos Bolt, and it's an ability you've selected to parse, an announcement will be made on screen.

does the API allow for such calls?

semlar 08-07-13 09:09 PM

The combat log doesn't provide a target for SPELL_CAST_START events so the only way you could guess at a target would be if someone was targeting the warlock and you got which unit the warlock was targeting when they started casting, which isn't necessarily the target of the spell since they could be using mouseover or focus macros.

Nibelheim 08-07-13 09:11 PM

Quote:

Originally Posted by semlar (Post 282691)
The combat log doesn't provide a target for SPELL_CAST_START events so the only way you could guess at a target would be if someone was targeting the warlock and you got which unit the warlock was targeting when they started casting, which isn't necessarily the target of the spell since they could be using mouseover or focus macros, but I think that would be the best you could do.

With the re-introduction of cast bars on nameplates, would using Nameplates as a reference work? Not sure if you can get target info from Nameplates, though.

Phanx 08-07-13 10:07 PM

Nope. Watching nameplate castbars will still only tell you that someone, somewhere, is casting the spell, not who they're casting it on. You can only find out who they're targeting if you target them or mouse over them (or their nameplate) so they get a unit token.

Nibelheim 08-07-13 10:14 PM

Quote:

Originally Posted by Phanx (Post 282695)
Nope. Watching nameplate castbars will still only tell you that someone, somewhere, is casting the spell, not who they're casting it on. You can only find out who they're targeting if you target them or mouse over them (or their nameplate) so they get a unit token.

Ah well, was a bit much to hope for :p

ravagernl 08-08-13 05:11 AM

Kollektiv's SpellAlerter used to be able to do this, but I have no idea if it works for MoP.

[EDIT] There's a fan update of spellalerter for 5.1.

launchcodemexico 08-09-13 04:51 PM

so Kollektiv's Spellcaster seems to be at odds with what Semlar and Phanx mentioned. did this event used to exist? and has it been removed since MOP?

or does the old Spellcaster use some elaborate workaround to search targeted enemies within your group for hostiles targeting you?

ravagernl 08-09-13 04:54 PM

Quote:

Originally Posted by launchcodemexico (Post 282827)
so Kollektiv's Spellcaster seems to be at odds with what Semlar and Phanx mentioned. did this event used to exist? and has it been removed since MOP?

or does the old Spellcaster use some elaborate workaround to search targeted enemies within your group for hostiles targeting you?

Spellalerter looks at the unit's target at the moment of casting. If the target can't be detected, it's not displayed.

semlar 08-09-13 05:54 PM

If someone in your group is targeting the unit when it starts casting, you can detect that they started casting and you can get what unit they're currently targeting.

This is fine for most spells that mobs cast, although a handful of abilities can be cast on another unit without the mob switching targets.

Players, on the other hand, do not require targeting a unit to cast on it. In the majority of cases this won't matter. HOWEVER, in the arena you will run into a huge number of players who use macros to cast on either their mouseover target or a specific arena member not only because it's faster but it also prevents YOU from knowing who they're casting on.

Almost all healers will also be using either mouseover macros or click casting on unit frames which will also prevent you from detecting who they're casting on.


All times are GMT -6. The time now is 11:05 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI