mirror of
https://github.com/brues-code/ClassicAPI.git
synced 2026-11-16 08:00:42 +00:00
feat(spell): fill notInterruptible in UnitCastingInfo / UnitChannelInfo
Mirror the 3.3.5 client's own predicate on 1.12 data instead of pushing a placeholder false. The value is relative to the local player: the spellbook is folded into school masks of INTERRUPT_CAST spells and MOD_SILENCE spells (cached on Player::StatSignal), a cast is not interruptible when its PreventionType is not SILENCE or when the caster's immunity auras (effect / state / school / mechanic immunity) strip every mask, and the flag is never reported while the player knows no interrupt or silence at all. 1.12 differences, each documented in Spell::Interruptible: the vanilla server's interrupt effect also needs InterruptFlags 0x02 (channels: ChannelInterruptFlags 0x04), which silence ignores; SMSG_SPELL_START carries no immunity block, so creature_template interrupt immunity stays invisible; Feral Charge's interrupt lives on its triggered spell, so the capability walk follows one TRIGGER_SPELL hop. Verified in-game: a paladin's Holy Light reads false, flips to true while Divine Shield is up, and back to false when it drops. Also centralize SPELL_EFFECT_APPLY_AURA in Offsets.h (was local to Level.cpp).
This commit is contained in:
+14
-5
@@ -15286,9 +15286,18 @@ so progress is `(GetTime()*1000 - startTimeMs) / (endTimeMs - startTimeMs)`.
|
||||
> the cast's **castGUID** — the exact string the
|
||||
> [`UNIT_SPELLCAST_*`](#unit_spellcast_-events) events carry for this cast,
|
||||
> so you can correlate the polled info with the events (works for the player
|
||||
> and other units). Fields that can't be filled are structurally-correct
|
||||
> placeholders: `castBarID` = `nil`, `notInterruptible` = `false`,
|
||||
> `delayTimeMs` = `0`.
|
||||
> and other units). `delayTimeMs` is the pushback the cast has taken so far,
|
||||
> in milliseconds. `castBarID` has no source here and is always `nil`.
|
||||
>
|
||||
> `notInterruptible` is `true` when no interrupt or silence that **you**
|
||||
> know can stop the cast. The value is relative to your own abilities, so a
|
||||
> rogue and a mage can read different values for the same cast. It is `true`
|
||||
> in two cases: the spell can never be interrupted, or the caster has an aura
|
||||
> that blocks every interrupt and silence you know (for example Divine Shield,
|
||||
> Ice Block, or Banish). If you know no interrupt and no silence, the value is
|
||||
> always `false`. Limits: a creature's built-in interrupt immunity is
|
||||
> server-side data that the client never receives, so a boss with that
|
||||
> immunity reads `false` while your interrupt still fails on it.
|
||||
|
||||
### `C_Spell.UnitChannelInfo(unit)` / `C_Spell.ChannelInfo()`
|
||||
|
||||
@@ -15316,8 +15325,8 @@ as casts: when we observed the channel begin, the remote unit returns full
|
||||
**start/end times** (validated against the live `UNIT_FIELD_CHANNEL_SPELL`
|
||||
so a stale cache entry never applies to a different/ended channel);
|
||||
otherwise it falls back to `name`/`displayName`/`textureID`/`spellID` with
|
||||
**`nil` times**. The player path is unchanged (full timing). Same
|
||||
placeholder fields as `C_Spell.UnitCastingInfo`.
|
||||
**`nil` times**. The player path is unchanged (full timing).
|
||||
`notInterruptible` follows the same rules as in `C_Spell.UnitCastingInfo`.
|
||||
|
||||
### `C_Spell.GetSpellLevelInfo(spellID)`
|
||||
|
||||
|
||||
Reference in New Issue
Block a user