From 25ef1b9362eb8965eaac5fd5d667bbb5cbc76518 Mon Sep 17 00:00:00 2001 From: ragnarok-clanker Date: Sat, 31 Oct 2026 01:25:31 +0000 Subject: [PATCH] Decompile 2 functions in Source/Contents/Effects/MonsterSkillEffects.cpp, Source/Contents/Effects/MonsterSkillEffects.h Batch #6801 by eAthena: 1 byte-identical, 1 confirmed by peer review. - fn_07307 CDropItemEffect::Slot01: logic confirmed by peer review - fn_07323 CJupitelThunderHit::Slot01: byte-identical Peer-reviewed-by: alisonrag, superintelligence, Tanke Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes). --- .../Contents/Effects/MonsterSkillEffects.cpp | 52 +++++++++++++++++++ Source/Contents/Effects/MonsterSkillEffects.h | 11 +++- 2 files changed, 61 insertions(+), 2 deletions(-) diff --git a/Source/Contents/Effects/MonsterSkillEffects.cpp b/Source/Contents/Effects/MonsterSkillEffects.cpp index 5d8808e6..881e5f50 100644 --- a/Source/Contents/Effects/MonsterSkillEffects.cpp +++ b/Source/Contents/Effects/MonsterSkillEffects.cpp @@ -908,6 +908,40 @@ CDropItemEffect::CDropItemEffect() this->emitters.resize(this->emitterCount); } +// OFFSET: 0x00719400 +// FUNCTION: fn_07307 +void CDropItemEffect::Slot01() { + if (!static_cast(g_modeMgr.GetGameMode())->scene) { + return; + } + + for (int i = 0; i < this->emitterCount; ++i) { + EZ2STREmitter* emitter = + reinterpret_cast(CreateEZ2STRParticle(reinterpret_cast(this->CEffect::position), 5)); + if (!emitter) { + return; + } + + InitParticleQuad(AsParticle(emitter)->vertices); + this->emitters.push_back(emitter); + } + + this->OpenEmitters(); + this->Slot12(); + static_cast(g_modeMgr.GetGameMode())->scene->GetItemByAID(this->actor); + this->position.x = this->CEffect::position[0]; + this->position.y = this->CEffect::position[1]; + this->position.z = this->CEffect::position[2]; + for (std::size_t i = 0; i < this->emitters.size(); ++i) { + EZ2STREmitter* emitter = this->emitters[i]; + if (emitter) { + emitter->position = this->position; + } + } +} + +// OFFSET: 0x00719520 + // OFFSET: 0x00719660 // FUNCTION: fn_07309 bool CDropItemEffect::Slot06() { @@ -922,6 +956,8 @@ bool CDropItemEffect::Slot06() { return true; } +// OFFSET: 0x00719690 + // OFFSET: 0x00719C30 // FUNCTION: fn_07311 void CDropItemEffect::Slot03() { @@ -949,6 +985,20 @@ CJupitelThunderHit::CJupitelThunderHit() : CEffect(-1) { this->unknown_002C = 250; } +// OFFSET: 0x0071BAB0 + +// OFFSET: 0x0071C270 + +// OFFSET: 0x0071C520 +// FUNCTION: fn_07323 +void CJupitelThunderHit::Slot01() { + if (this->id != 1200) { + this->SpawnSpark(); + } + + this->SpawnHit(); +} + // OFFSET: 0x0071C540 // FUNCTION: fn_07324 bool CJupitelThunderHit::Slot06() { @@ -963,6 +1013,8 @@ bool CJupitelThunderHit::Slot06() { return this->frame < this->unknown_002C; } +// OFFSET: 0x0071C570 + // OFFSET: 0x0071CB70 // FUNCTION: fn_07326 void CJupitelThunderHit::Slot04() { diff --git a/Source/Contents/Effects/MonsterSkillEffects.h b/Source/Contents/Effects/MonsterSkillEffects.h index e69f70ed..86436375 100644 --- a/Source/Contents/Effects/MonsterSkillEffects.h +++ b/Source/Contents/Effects/MonsterSkillEffects.h @@ -410,13 +410,17 @@ public: class CJupitelThunderHit : public CEffect { public: CJupitelThunderHit(); + void Slot01() override; + void Slot03() override; void Slot04() override; bool Slot06() override; void Close() override; + void SpawnHit(); + void SpawnSpark(); /* 00CC */ std::vector emitters; /* 00D8 */ std::vector unknown_00D8; - /* 00E4 */ std::vector unknown_00E4; + /* 00E4 */ std::vector textures; }; class CNewCloudKillEffect : public CEffect { @@ -440,10 +444,13 @@ public: class CDropItemEffect : public CEffect { public: CDropItemEffect(); + void Slot01() override; void Slot03() override; void Slot04() override; bool Slot06() override; void Close() override; + void Slot12() override; + void OpenEmitters(); /* 00CC */ int unknown_00CC; /* 00D0 */ int emitterCount; @@ -515,7 +522,7 @@ static_assert(sizeof(CSevereRainStorm) == 0xD8); static_assert(sizeof(CGaleStorm) == 0xE0); static_assert(offsetof(CGaleStorm, unknown_00D8) == 0xD8); static_assert(sizeof(CJupitelThunderHit) == 0xF0); -static_assert(offsetof(CJupitelThunderHit, unknown_00E4) == 0xE4); +static_assert(offsetof(CJupitelThunderHit, textures) == 0xE4); static_assert(sizeof(CNewCloudKillEffect) == 0xFC); static_assert(offsetof(CNewCloudKillEffect, unknown_00F4) == 0xF4); static_assert(offsetof(CDropItemEffect, emitters) == 0xD4);