- Fixed possible exploit with tamed pets having template immunities
- Implemented binary resistances
- Corrected resistances calculations
- Pets properly inherit players spell penetration
- Fixed doubled block calculation for damaging melee spells
- Auras removing snare effects will only remove the snaring component
- Shapeshifting will properly remove movement impairing auras only and not crowd control (dragon's breath)
- Immunities are properly checked versus all schools appearing in spell, unit is immune only if immune to all schools
- Spells with melee and magic school mask should compare armor reduction with resistances and select smaller reduction
- Demonic Circle: Teleport no longer removes root effects
(cherrypicked from 93746e8c4a)
* Remade trajectory target selection
* Added possibility to apply conditions to trajectory spells
* Properly recalculate delay time if CMSG_UPDATE_PROJECTILE_POSITION is received
(cherrypicked from c6060dd0c5)
- Spell attributes research
- Container optimization
- Do not skip damage immunity checks on SPELL_ATTR0_UNAFFECTED_BY_INVULNERABILITY present
- Added additonal arguments support to SendCastResult / CheckCast, spells can now send proper error messages
- Loads spell immune masks/states/effects at startup.
- This cached info is used whenever a spell cast requires immunities to be known beforehand (to see if an aura could be applied for example)
Closes#16658Closes#16901Closes#18114
(cherry picked from commit 50a3ce5703)
Core/Spell: fix warning
(cherry picked from commit 3588ff894b)
Core/Unit: misc codestyle
use typedef for constant reference
(cherry picked from commit 7943150dcb)
Core/Spell: Fixed immunities for some spells (they were broken before rewrite too)
- Warlord's Presence, Uncontrollable Frenzy, Free Friend
- Overload, Lightning Tendrils
- Fervor, Berserk
- Determination
(cherry picked from commit fc6844173f)
Core/Spell: fix typos
(cherry picked from commit f060efbdb4)
Core/Unit: improved handling of some spell attributes
- SPELL_ATTR1_UNAFFECTED_BY_SCHOOL_IMMUNE
- SPELL_ATTR2_UNAFFECTED_BY_AURA_SCHOOL_IMMUNE
- SPELL_ATTR3_IGNORE_HIT_RESULT
(cherry picked from commit 352c84943c)
Core/Spell: fix typo
Closes#18248
(cherry picked from commit 1ad9c7d3fd)
Core/Spell: perform charmer check against player controlling unit. Fixes spellcasts while charmed
(cherry picked from commit 425f6c3c34)
Core/Unit: don't use damage immunity to calculate hit result for the whole spell. Should be used only for damage
(cherry picked from commit 9f5df023b7)
Core/Spell: fix a potential null dereference crash
(cherry picked from commit 64304d8b2b)
Auto repeat spells are casted as triggered and didn't register procs properly if the aura can't proc with triggered
(cherry picked from commit aaa1a43204)
* Core/Spells: Implementation of QAston proc system
- Move checks from Unit::IsTriggeredAtSpellProcEvent (old system) to Aura::IsProcTriggeredOnEvent (new system)
- killed charge counter from SpellModifier and Player system for handling charges... no point in having 3 different systems doing the same thing
- Automatically add default entries to spellProcMap, based on spellinfo (else auras won't proc without an entry) Based on old Unit::ProcDamageAndSpellFor
- Old Unit::ProcDamageAndSpellFor renamed to Unit::ProcSkillsAndReactives and made private, will no longer handle auras.
- Start making use of HealInfo::AbsorbHeal in unit calculations, add effective healing info to HealInfo struct
- Changes in spell reflection system, emulates old behaviour, delaying aura drop
- Removed old charge count hacks in SpellMgr::LoadSpellInfoCorrections
- Removed bogus error log when procChance is 0: Some auras have initial 0 procChance but modified by SPELLMOD_CHANCE_OF_SUCCESS
- Fixed TriggerAurasProcOnEvent logic that tried to trigger twice from actor.
- Allow non damaging spells with DamageClass Melee or Ranged to proc character enchants. Ref issue #17034:
* http://web.archive.org/web/20110309092008/http://elitistjerks.com/f47/t49865-paladin_retribution_pve/
* When an auto-attack lands (does not dodge/parry/miss) that can proc a seal the of the following things happen independently of each other (see 2 roll system).
* 1) A "hidden strike" which uses melee combat mechanics occurs. If it lands it refreshes/stacks SoV DoT. Only white swings can trigger a refresh or stack. (This hidden strike mechanic can also proc things like berserking..)
* 2) A weapon damage based proc will occur if you used a special (CS/DS/judge) or if you have a 5 stack (from auto attacks). This attack can not be avoided.
* Holy Vengeance is the "hidden strike" it has an apply aura effect and damage class melee.
- Fixed Blood Tap interaction with Death Runes (btw, don't know what was going on with those MiscValueB, spell 45529 doesn't have any MiscValueB in SPELL_EFFECT_ACTIVATE_RUNE)
- Ported some AuraEffect checks from old Unit.cpp function. added new AuraScript hook to check procs of an specific effect
- Allow only AuraEffects that passed the check to proc, this won't block whole aura from proccing (and lose charges) if at least one of the effects procs, though
- Changes in spell mod system (for SPELLMOD_CASTING_TIME). fixes#17558.
- Added an exception for SPELLMOD_CRITICAL_CHANCE too, fixes#15193
(cherry picked from commit e641d0c7d7)
# Conflicts:
# sql/base/auth_database.sql
# src/server/game/Entities/Player/Player.cpp
# src/server/game/Entities/Player/Player.h
# src/server/game/Entities/Unit/Unit.cpp
# src/server/game/Entities/Unit/Unit.h
# src/server/game/Spells/Auras/SpellAuraEffects.cpp
# src/server/game/Spells/Auras/SpellAuras.cpp
# src/server/game/Spells/Auras/SpellAuras.h
# src/server/game/Spells/Spell.cpp
# src/server/game/Spells/SpellEffects.cpp
# src/server/game/Spells/SpellInfo.cpp
# src/server/game/Spells/SpellMgr.cpp
# src/server/game/Spells/SpellMgr.h
# src/server/game/Spells/SpellScript.cpp
* Mostly aimed at removing Log/DatabaseEnv includes from other headers
* Fix most packet headers including other packet headers - moved common structures such as ItemInstance to their own files
* Moved SAI function definitions to source files (massive or requiring many different dependencies)