// // GJBaseGameLayer::applyShake from 0x10015b150 to 0x10015b270 (288 bytes) // // 0 xrefs: // // This function is hookable on this platform! // // Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings // void __fastcall GJBaseGameLayer::applyShake(GJBaseGameLayer *a1, cocos2d::CCPoint *a2) { double m_totalTime; // xmm0_8 double m_unkUint64_1; // xmm1_8 bool m_staticCameraShake; // r15 __m128 v5; // xmm0 __m128 v6; // xmm0 __m128 v7; // xmm1 float m_unkUint16; // xmm2_4 float v9; // xmm1_4 __m128 m_unkPoint34; // xmm0 __m128 inserted; // xmm1 __m128 v12; // [rsp+0h] [rbp-30h] m_totalTime = a1->m_gameState.m_totalTime; m_unkUint64_1 = a1->m_gameState.m_unkUint64_1; if ( m_unkUint64_1 < 0.0 || (m_unkUint16 = a1->m_gameState.m_unkUint16, m_unkUint16 <= 0.0) || (v9 = m_totalTime - m_unkUint64_1, v9 > m_unkUint16) ) { a1->m_gameState.m_unkUint64_1 = m_totalTime; m_staticCameraShake = a1->m_staticCameraShake; v5 = 0; v5.f32[0] = (float)rand() * 4.6566129e-10; v12 = v5; v6 = 0; v6.f32[0] = (float)rand() * 4.6566129e-10; if ( m_staticCameraShake ) { v7 = _mm_blendv_ps( (__m128)xmmword_1008154C0, (__m128)xmmword_1008154E0, _mm_cmplt_ps((__m128)xmmword_100816970, _mm_insert_ps(v12, v6, 16))); } else { inserted = _mm_insert_ps(v12, v6, 16); v7 = _mm_add_ps(_mm_add_ps(inserted, inserted), (__m128)xmmword_1008154C0); } m_unkPoint34 = _mm_mul_ps(_mm_moveldup_ps((__m128)LODWORD(a1->m_gameState.m_unkUint15)), v7); _mm_storel_ps((double *)&a1->m_gameState.m_unkPoint34, m_unkPoint34); } else { m_unkPoint34 = (__m128)(unsigned __int64)a1->m_gameState.m_unkPoint34; } _mm_storel_ps((double *)a2, _mm_add_ps((__m128)*(_QWORD *)a2, m_unkPoint34)); }
GD Web Decomp Icon

GD Web Decomp

Raw Source