From 81ce194ace2f8984e3f4739caeaf8b89f0de2bdb Mon Sep 17 00:00:00 2001 From: ragnarok-clanker Date: Thu, 12 Nov 2026 15:38:53 +0000 Subject: [PATCH] Decompile fn_18952 (CMapChainEffect::OnProcess) Batch #17975 by eAthena: 0 byte-identical, 1 confirmed by peer review. - fn_18952 CMapChainEffect::OnProcess: logic confirmed by peer review Peer-reviewed-by: ragnarok-clanker, Yommy, alisonrag, kyoshi Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes). --- Source/Contents/Effects/Skills/MapChainEffect.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Source/Contents/Effects/Skills/MapChainEffect.cpp b/Source/Contents/Effects/Skills/MapChainEffect.cpp index 328263c6c..fcf79ea64 100644 --- a/Source/Contents/Effects/Skills/MapChainEffect.cpp +++ b/Source/Contents/Effects/Skills/MapChainEffect.cpp @@ -122,10 +122,11 @@ bool CMapChainEffect::IsAlive() { // FUNCTION: fn_18952 void CMapChainEffect::OnProcess() { for (std::vector::iterator it = this->particles.begin(); it != this->particles.end(); ++it) { - (*it)->position.x = this->position[0]; - (*it)->position.y = this->position[1]; - (*it)->position.z = this->position[2]; CParticle* particle = *it; + vector3d& position = (*it)->position; + position.x = this->position[0]; + position.y = this->position[1]; + position.z = this->position[2]; if (particle) { float angle = *reinterpret_cast(particle->animationParameters) + *reinterpret_cast(&particle->angleBits); if (angle >= 360.0f) { @@ -145,10 +146,9 @@ void CMapChainEffect::OnProcess() { particle->alpha = alpha > 0 ? alpha : 0; } - const CView* view = static_cast(g_modeMgr.GetGameMode())->camera; matrix rotation; std::memcpy(rotation.values, g_identityMatrix, sizeof(rotation.values)); - rotation.MakeYRotation(view->camera.yaw / -180.0f * 3.141592f); + rotation.MakeYRotation(static_cast(g_modeMgr.GetGameMode())->camera->camera.yaw / -180.0f * 3.141592f); particle->transform = rotation; const int segment = particle->columnIndex;