Skip to content

Decomp effect 052 - #85

Merged
roengstrom merged 2 commits into
mainfrom
decomp-effect_052
Sep 9, 2026
Merged

Decomp effect 052#85
roengstrom merged 2 commits into
mainfrom
decomp-effect_052

Conversation

@roengstrom

Copy link
Copy Markdown
Owner

Decomp the entirety of the effect_052 overlay

X-Potion runs the engine Curaga already carries, so 99 of its 118 functions
are the library: nineteen units, listed in its own link order, and a symbol
file that maps their names onto its addresses. Deriving that map is the whole
of the work -- align unit by unit and position by position, because two
functions of one unit can hash alike when they differ only in which sibling
they call, and pair the relocation streams off against each other. 244
addresses paired with nothing left in conflict.

What is X-Potion's own is the entry, a root dispatcher and seventeen script
functions, and all but one of those are byte-identical to Curaga's or Cure's,
so they came across with the addresses rewritten. Only the bank carve was
written here. Its rings are Curaga's sizes, so its parameter header is the
same two counts; what differs is the pool: X-Potion has no trailing-spark
pool, which is why its entry sets up three where Curaga sets up four and its
dispatcher drains three.

Three things the overlay needed from its config. splat does not carve out a
lone `jr ra` no-op, and three of them sit between script functions, so they
are named in the symbol file or the binary comes out short and every later
address shifts. The asset blob was declared from 0x9BF0, which swallowed the
script dispatch tables; it starts at 0x9C68. And the jump tables carry the
tail pad ASFLAGS suppress, so the pad between particlestep's and list's is
declared.
The port left the entry taking its prototype from effect_028_entry.h, the
overlay it was copied from. Both overlays declare the same signature under
the same name, so it compiled and the binary matched -- nothing but reading
the include would have shown it. X-Potion's entry now owns its declaration,
the way the other three overlays' do.
@decomp-dev

decomp-dev Bot commented Sep 9, 2026

Copy link
Copy Markdown

Report for SLUS_008.92 (e3acf06 - 612fa36)

Total code: 1293120 bytes (+39900 bytes)
Total functions: 4917 (+118)
📈 Matched code: 50.88% (+1.56%, +39900 bytes)
Total data: 26832 bytes (+136 bytes)
📈 Matched data: 58.06% (+0.21%, +136 bytes)

✅ 163 new matches
Unit Item Bytes Before After
ovl/effect_052/lib/spawn effectEmitterSpawn +2716 0.00% 100.00%
ovl/effect_052/lib/spawn effectEmitterSlide +2672 0.00% 100.00%
ovl/effect_052/lib/particlestep effectParticlePose +2368 0.00% 100.00%
ovl/effect_052/lib/particlestep effectParticleAdvance +2056 0.00% 100.00%
ovl/effect_052/lib/draw effectSpriteEmit +1580 0.00% 100.00%
ovl/effect_052/lib/emit effectEmitGouraudTexQuads +1096 0.00% 100.00%
ovl/effect_052/lib/emit effectEmitTexQuads +996 0.00% 100.00%
ovl/effect_052/lib/emit effectEmitGouraudTexTris +956 0.00% 100.00%
ovl/effect_052/lib/emit effectEmitTexTris +904 0.00% 100.00%
ovl/effect_052/lib/emit effectEmitGouraudQuads +904 0.00% 100.00%
ovl/effect_052/lib/emit effectEmitQuads +804 0.00% 100.00%
ovl/effect_052/lib/emit effectEmitGouraudTris +776 0.00% 100.00%
ovl/effect_052/lib/tint effectTintPlay +732 0.00% 100.00%
ovl/effect_052/lib/emit effectEmitTris +716 0.00% 100.00%
ovl/effect_052/lib/strands effectStrandsAim +712 0.00% 100.00%
ovl/effect_052/lib/drawscript effectDrawScriptStart +680 0.00% 100.00%
ovl/effect_052/lib/tables effectPoseTablesRelocate +676 0.00% 100.00%
ovl/effect_052/lib/spawn effectEmitterOnStrand +648 0.00% 100.00%
ovl/effect_052/lib/draw effectSpritePacket +616 0.00% 100.00%
ovl/effect_052/lib/entity effectUpdateModelBounds +588 0.00% 100.00%
ovl/effect_052/lib/emit effectEmitStream +580 0.00% 100.00%
ovl/effect_052/lib/list effectEmitterSetup +564 0.00% 100.00%
ovl/effect_052/lib/spawn effectEmitterOnOwner +528 0.00% 100.00%
ovl/effect_052/lib/packet effectBuildMeshPacket +520 0.00% 100.00%
ovl/effect_052/lib/spawn effectEmitterOnTrail +520 0.00% 100.00%
ovl/effect_052/effect_052 func_801A99EC +496 0.00% 100.00%
ovl/effect_052/effect_052_entry func_801A0000 +492 0.00% 100.00%
ovl/effect_052/lib/vector effectBlendPointSets +404 0.00% 100.00%
ovl/effect_052/lib/common effectMatrixRotX +400 0.00% 100.00%
ovl/effect_052/lib/common effectMatrixRotY +396 0.00% 100.00%

...and 133 more new matches

@roengstrom
roengstrom merged commit 612fa36 into main Sep 9, 2026
1 check passed
@roengstrom
roengstrom deleted the decomp-effect_052 branch September 9, 2026 20:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant