[Decomp][Spell] Cohesion split: extract Spell.cpp pipeline to Spell*.cpp - #220
Merged
Merged
Conversation
Mirror of mangosthree mangostwo#197-207 (bundled, same source file). Pure cohesion split of Spell.cpp (10,284 -> 1,828 lines) with no behaviour change. The cast pipeline / targeting / checks move to dedicated TUs: - SpellPackets.cpp - packet senders. - SpellChecks.cpp - pre-cast validation (CheckCast and friends). - SpellTargeting.cpp - SetTargetMap selection (carries the ChainHealing/ TargetDistance sort functors). - SpellCast.cpp - cast pipeline (prepare/cast/finish). - SpellHit.cpp - effect delivery to target. - SpellPower.cpp - power/cost calculation. - SpellCooldown.cpp - global cooldown. - SpellTargetList.cpp - target-list assembly. - SpellEffectDispatch.cpp- per-effect dispatch (externs the SpellEffects table). - SpellCheckTarget.cpp - target validation. - SpellAreaTargets.cpp - area/raid targeting (carries the Prioritize mana/health priority-queue helpers). Spell.h is unchanged. CMake file(GLOB) auto-compiles the new TUs.
Not up to standards ⛔🔴 Issues
|
| Category | Results |
|---|---|
| UnusedCode | 2 medium |
| Performance | 1 medium |
🟢 Metrics 2552 complexity · 43 duplication
Metric Results Complexity 2552 Duplication 43
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.
|
❌ Build Mangos TWO Server 22.04.63 failed (commit 75af42c953 by @r-log) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Mirror of mangosthree #197-207 (bundled — all touch
Spell.cpp). Pure cohesion split ofSpell.cpp(10,284 → 1,828 lines) with no behaviour change. The 61 cast-pipeline / targeting / check methods move to 11 dedicated TUs:SpellPackets·SpellChecks·SpellTargeting(carries the ChainHealing/TargetDistance sort functors) ·SpellCast·SpellHit·SpellPower·SpellCooldown·SpellTargetList·SpellEffectDispatch(externs theSpellEffectsdispatch table) ·SpellCheckTarget·SpellAreaTargets(carries thePrioritize*mana/health priority-queue helpers).Spell.huntouched. CMakefile(GLOB)auto-compiles the new TUs. Verbatim move (incl. template-prefixed methods + the file-local sort/priority helpers), no dropped/duplicated defs. Builds clean (MSVC 2022, Release).Completes the Spell trio split alongside SpellEffects (#218) and SpellAuras (#219).
This change is