diff --git a/data/sql/updates/pending_db_world/rev_1791016638521201596.sql b/data/sql/updates/pending_db_world/rev_1791016638521201596.sql new file mode 100644 index 0000000000..e18fa94513 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1791016638521201596.sql @@ -0,0 +1,25 @@ +-- SPELL_ATTR0_CU_IGNORE_BINARY (512) for spells that must not be auto-classified as binary. +-- Replaces the hardcoded id list in SpellMgr::LoadSpellInfoCustomAttributes. +DELETE FROM `spell_custom_attr` WHERE `spell_id` IN (62457, 62469, 62576, 62580, 62583, 62597, 62601, 62602, 62604, 62605, 65370, 69425, 69649, 70827, 71056, 71057, 71058, 73061, 73062, 73063, 73064); +INSERT INTO `spell_custom_attr` (`spell_id`, `attributes`) VALUES +(62457, 512), -- Ice Shards (Hodir, small) +(62469, 512), -- Freeze (Hodir) +(62576, 512), -- Blizzard (Thorim 10m) +(62580, 512), -- Frostbolt Volley (Thorim 10m) +(62583, 512), -- Frostbolt (Thorim 10m) +(62597, 512), -- Frost Nova (Thorim 10m) +(62601, 512), -- Frostbolt (Thorim 25m) +(62602, 512), -- Blizzard (Thorim 25m) +(62604, 512), -- Frostbolt Volley (Thorim 25m) +(62605, 512), -- Frost Nova (Thorim 25m) +(65370, 512), -- Ice Shards (Hodir, big) +(69425, 512), -- Ice Shards (Pit of Saron) +(69649, 512), -- Frost Breath (Sindragosa) +(70827, 512), -- Ice Shards (Pit of Saron) +(71056, 512), -- Frost Breath (Sindragosa) +(71057, 512), -- Frost Breath (Sindragosa) +(71058, 512), -- Frost Breath (Sindragosa) +(73061, 512), -- Frost Breath (Sindragosa) +(73062, 512), -- Frost Breath (Sindragosa) +(73063, 512), -- Frost Breath (Sindragosa) +(73064, 512); -- Frost Breath (Sindragosa) diff --git a/src/server/game/Spells/SpellInfo.h b/src/server/game/Spells/SpellInfo.h index 416ef7a818..6536b82da6 100644 --- a/src/server/game/Spells/SpellInfo.h +++ b/src/server/game/Spells/SpellInfo.h @@ -183,7 +183,7 @@ enum SpellCustomAttributes SPELL_ATTR0_CU_DONT_BREAK_STEALTH = 0x00000040, SPELL_ATTR0_CU_NO_PVP_FLAG = 0x00000080, SPELL_ATTR0_CU_DIRECT_DAMAGE = 0x00000100, - SPELL_ATTR0_CU_CHARGE = 0x00000200, + SPELL_ATTR0_CU_IGNORE_BINARY = 0x00000200, SPELL_ATTR0_CU_PICKPOCKET = 0x00000400, SPELL_ATTR0_CU_IGNORE_EVADE = 0x00000800, SPELL_ATTR0_CU_NEGATIVE_EFF0 = 0x00001000, diff --git a/src/server/game/Spells/SpellMgr.cpp b/src/server/game/Spells/SpellMgr.cpp index 93d57e3cc0..ea99b0e0a9 100644 --- a/src/server/game/Spells/SpellMgr.cpp +++ b/src/server/game/Spells/SpellMgr.cpp @@ -3357,13 +3357,6 @@ void SpellMgr::LoadSpellInfoCustomAttributes() case SPELL_EFFECT_CREATE_ITEM: spellInfo->AttributesCu |= SPELL_ATTR0_CU_NO_INITIAL_THREAT; break; - case SPELL_EFFECT_CHARGE: - case SPELL_EFFECT_CHARGE_DEST: - case SPELL_EFFECT_JUMP: - case SPELL_EFFECT_JUMP_DEST: - case SPELL_EFFECT_LEAP_BACK: - spellInfo->AttributesCu |= SPELL_ATTR0_CU_CHARGE; - break; case SPELL_EFFECT_PICKPOCKET: spellInfo->AttributesCu |= SPELL_ATTR0_CU_PICKPOCKET; break; @@ -3405,7 +3398,7 @@ void SpellMgr::LoadSpellInfoCustomAttributes() } // Xinef: spells ignoring hit result should not be binary - if (!spellInfo->HasAttribute(SPELL_ATTR3_ALWAYS_HIT)) + if (!spellInfo->HasAttribute(SPELL_ATTR3_ALWAYS_HIT) && !spellInfo->HasAttribute(SPELL_ATTR0_CU_IGNORE_BINARY)) { for (uint8 j = 0; j < MAX_SPELL_EFFECTS; ++j) { @@ -3443,16 +3436,9 @@ void SpellMgr::LoadSpellInfoCustomAttributes() !spellInfo->HasAttribute(SPELL_ATTR0_NO_IMMUNITIES)))) continue; - if (spellInfo->Id == 69649 || spellInfo->Id == 71056 || spellInfo->Id == 71057 || spellInfo->Id == 71058 || - spellInfo->Id == 73061 || spellInfo->Id == 73062 || spellInfo->Id == 73063 || spellInfo->Id == 73064) - continue; - if (spellInfo->SpellFamilyName == SPELLFAMILY_MAGE && (spellInfo->SpellFamilyFlags[0] & 0x20)) // Frostbolt continue; - if (spellInfo->Id == 55095) // Frost Fever - continue; - if (spellInfo->SpellFamilyName == SPELLFAMILY_WARLOCK && ((spellInfo->SpellFamilyFlags[1] & 0x40000) || (spellInfo->SpellFamilyFlags[0] & 0x4000))) // Haunt/Drain Soul continue; diff --git a/src/server/scripts/Commands/cs_spellinfo.cpp b/src/server/scripts/Commands/cs_spellinfo.cpp index 5b2523ce3f..176f726eaa 100644 --- a/src/server/scripts/Commands/cs_spellinfo.cpp +++ b/src/server/scripts/Commands/cs_spellinfo.cpp @@ -786,7 +786,7 @@ public: if (spell->AttributesCu & SPELL_ATTR0_CU_DONT_BREAK_STEALTH) handler->PSendSysMessage(" - SPELL_ATTR0_CU_DONT_BREAK_STEALTH"); if (spell->AttributesCu & SPELL_ATTR0_CU_NO_PVP_FLAG) handler->PSendSysMessage(" - SPELL_ATTR0_CU_NO_PVP_FLAG"); if (spell->AttributesCu & SPELL_ATTR0_CU_DIRECT_DAMAGE) handler->PSendSysMessage(" - SPELL_ATTR0_CU_DIRECT_DAMAGE"); - if (spell->AttributesCu & SPELL_ATTR0_CU_CHARGE) handler->PSendSysMessage(" - SPELL_ATTR0_CU_CHARGE"); + if (spell->AttributesCu & SPELL_ATTR0_CU_IGNORE_BINARY) handler->PSendSysMessage(" - SPELL_ATTR0_CU_IGNORE_BINARY"); if (spell->AttributesCu & SPELL_ATTR0_CU_PICKPOCKET) handler->PSendSysMessage(" - SPELL_ATTR0_CU_PICKPOCKET"); if (spell->AttributesCu & SPELL_ATTR0_CU_IGNORE_EVADE) handler->PSendSysMessage(" - SPELL_ATTR0_CU_IGNORE_EVADE"); if (spell->AttributesCu & SPELL_ATTR0_CU_NEGATIVE_EFF0) handler->PSendSysMessage(" - SPELL_ATTR0_CU_NEGATIVE_EFF0");