Thread Tools Display Modes
Prev Previous Post   Next Post Next
02-23-18, 03:33 AM   #1
doofus
A Chromatic Dragonspawn
Join Date: Feb 2018
Posts: 158
UNIT_SPELLCAST_SUCCEEDED and multiple results

I am using UNIT_SPELLCAST_SUCCEEDED to detect the spells that the player casts. I am not using the combat log.

I have noticed when I cast a spell, eg Frostbolt I receive two events, one when the spellcast is complete with event id 116, and another event when the spell hits with event id 228597. I presume this is for spells that can miss/resisted? Other spells, like Ice Lance only produce one and only event, as you'd expect.

If the second event is to notify me of a successful hit/miss/resisted and also of the travel time associated with some spells, then why do we not have a completely different event like "SPELL_HIT_MISS" or something similar?

How can an addon tell which events are the actual spell cast, and which are the result which due to travel time and due to hit/miss can have varying results?
  Reply With Quote
 

WoWInterface » Developer Discussions » Lua/XML Help » UNIT_SPELLCAST_SUCCEEDED and multiple results


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off