mirror of
https://github.com/brues-code/ClassicAPI.git
synced 2026-11-16 16:10:36 +00:00
* feat(combatlog): add COMBAT_LOG_EVENT and CombatLogGetCurrentEventInfo Port 4.3.4's combat log events (UnitCombatLog_C.cpp) in its argument layout: timestamp, subevent, hideCaster, source and dest GUID, name, flags and raid flags, then the spell prefix and the subevent suffix. - Swing, range, spell and periodic damage, misses, heals, energize, drain and leech, damage shields, split damage and environmental damage, read from the combat log messages through Net::PacketDispatch. - Spell misses from the one function every miss goes through, so a missile's miss is sent when it arrives. - Object flags and raid flags from the fields 4.3.4 reads. Names follow the 1.12 combat log namer's steps. - CombatLogGetCurrentEventInfo returns the values only while the events are being sent, as on Classic Era. - Event::Custom::FireValues sends an event with Lua values, so booleans and nils land where 4.3.4 puts them. - COMBATLOG_OBJECT_* constants in the addon. Overkill, overhealing and healing absorbs are 0: the server does not send them. * feat(combatlog): add casts, auras, dispels, interrupts and deaths Port 4.3.4's layer 2 combat log subevents: SPELL_CAST_START/SUCCESS/ FAILED, SPELL_AURA_APPLIED/REMOVED and their _DOSE forms, SPELL_DISPEL, SPELL_DISPEL_FAILED, SPELL_INTERRUPT, SPELL_EXTRA_ATTACKS, SPELL_DRAIN, SPELL_LEECH, SPELL_RESURRECT, SPELL_DURABILITY_DAMAGE(_ALL), SPELL_INSTAKILL, UNIT_DIED, UNIT_DESTROYED and PARTY_KILL, plus proc resists as SPELL_MISSED. Casts come from SPELL_START / SPELL_GO and the cast-fail log line, effects from SPELLLOGEXECUTE as the 1.12 client reads it, auras from the engine's aura handlers through a new Aura::Source change observer that carries the bound caster, and deaths from the death presentation. * feat(combatlog): add filters, kept entries and CombatLog_Object_IsA Port 4.3.4's UnitCombatLog_C_Scripts surface: CombatLogAddFilter / ResetFilter, the kept-entry functions (GetNumEntries, SetCurrentEntry, GetCurrentEntry, AdvanceEntry, ClearEntries), the retention time with its combatLogRetentionTime CVar, and CombatLog_Object_IsA. COMBAT_LOG_EVENT now fires only for entries that match the filters. Entries and filters clear on the return to the login screen. Adds the COMBATLOG_FILTER_* masks from 4.3.4's Constants.lua. * docs(combatlog): move the combat log events into the Events section * fix(combatlog): bound the execute-log loop and the retention time - Stop an execute log's target loop at an effect that carries nothing, so a huge target count cannot spin. - Clamp the retention time to what the wrap-safe age test can measure. - Bound GetCurrentEntry's index by the entry count. - List ENCHANT_APPLIED and ENCHANT_REMOVED among the subevents that do not fire, and note why effect 59 casts log SPELL_CAST_SUCCESS.