Getting spellId from CombatLogGetCurrentEventInfo in WoW Classic
Hello fellow developers!
I've been working on an addon for WoW Classic and currently hit a little bump.
I'm using the COMBAT_LOG_EVENT_UNFILTERED event to get information regarding spells being cast by certain players, their target and so on. I researched that the API requires you to use the CombatLogGetCurrentEventInfo() method to retrieve the event info like so:
But in Classic I don't get the spellId (Correction: I do get a spellId but it's always 0). However, I get every other combat log detail. The code works like intended on the retail version of WoW (See the full code below), but not in the Classic release. I know theres been changes to the WoW API to restrict certain methods and functionality. However, I've been unable to find any documentation regarding changing how the COMBAT_LOG_EVENT_UNFILTERED event and CombatLogGetCurrentEventInfo method functions. So I must be doing something wrong regarding how the API works with Classic? (Compared to retail)
Here's the full code:
So if anyone could help me out with my mistakes or point me in the direction of some useful documentation or examples, I would be really grateful!
Without looking at your code, I can personally tell you that classic's combat event is either currently bugged or specifically not showing spell IDs at all. I've had a personal code snippit for quite some time that emotes when I interrupt and links the interrupted spell. I thought it was just GetSpellLink not working (which currently doesn't link anyways) but the argument in the interrupt payload that gives the interrupted spell ID is 0, along with the casted spell ID also being 0.
You're going to have to match spell names and localize if it's for a public addon.
|All times are GMT -6. The time now is 07:09 PM.|
vBulletin © 2021, Jelsoft Enterprises Ltd
© 2004 - 2020 MMOUI