// // GJBaseGameLayer::spawnParticleTrigger from 0x140349ad0 to 0x140349eea (1050 bytes) // // 3 xrefs: // > GJBaseGameLayer::destroyObject @ 0x14031d510 // > EffectGameObject::triggerObject @ 0x140649655 // > @ 0x14091ffb8 // // This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True! // // Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings // Generated at Fri, 27 Nov 2026 11:30:44 +0000 // // Hidden C++ exception states: #wind=1 unsigned int __fastcall GJBaseGameLayer::spawnParticleTrigger(__int64 a1, __int64 a2, float *a3, float a4) { int v5; // ebx struct cocos2d::CCObject *Group; // r15 char v8; // r13 struct cocos2d::CCObject *MainObject; // rax __int64 v10; // rax unsigned int v11; // ebp unsigned int result; // eax struct cocos2d::CCObject *v13; // rax struct cocos2d::CCObject *v14; // rdi cocos2d::CCParticleSystem *v15; // rsi const struct cocos2d::CCPoint *v16; // rax float *v17; // rax float v18; // xmm11_4 float v19; // xmm7_4 float v20; // xmm10_4 float v21; // xmm8_4 float v22; // xmm9_4 float v23; // xmm6_4 float v24; // xmm0_4 float *v25; // rdx __int64 v26; // rbx __int64 v27; // rbx __int64 v28; // rbx __int64 v29; // rdx float v30; // [rsp+40h] [rbp-148h] BYREF float v31; // [rsp+44h] [rbp-144h] _BYTE v32[8]; // [rsp+48h] [rbp-140h] BYREF _BYTE v33[8]; // [rsp+50h] [rbp-138h] BYREF _BYTE v34[8]; // [rsp+58h] [rbp-130h] BYREF _BYTE v35[8]; // [rsp+60h] [rbp-128h] BYREF _BYTE v36[8]; // [rsp+68h] [rbp-120h] BYREF _BYTE v37[32]; // [rsp+70h] [rbp-118h] BYREF v5 = a2; Group = GJBaseGameLayer::getGroup(a1, a2); v8 = 0; cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v32); MainObject = GJBaseGameLayer::tryGetMainObject(a1, v5); if ( MainObject ) { v8 = 1; v10 = (*(__int64 (__fastcall **)(struct cocos2d::CCObject *))(*(_QWORD *)MainObject + 200LL))(MainObject); cocos2d::CCPoint::operator=(v32, v10); } v11 = 0; result = cocos2d::CCArray::count(Group); if ( result ) { do { v13 = cocos2d::CCArray::objectAtIndex(Group, v11); v14 = v13; if ( *((_DWORD *)v13 + 259) == 2065 ) { if ( *((_BYTE *)v13 + 1496) ) { *((_BYTE *)v13 + 1496) = 0; GameToolbox::particleStringToStruct((__int64 *)v13 + 183, (__int64)v13 + 1504); } sub_14003F4F0((__int64)v37, (__int64)v14 + 1464); v15 = (cocos2d::CCParticleSystem *)(*(__int64 (__fastcall **)(__int64, _BYTE *, _BYTE *))(*(_QWORD *)a1 + 1352LL))( a1, v37, (_BYTE *)v14 + 1504); sub_14003D310((__int64)v37); if ( v15 ) { if ( v8 ) { v16 = (const struct cocos2d::CCPoint *)(*(__int64 (__fastcall **)(struct cocos2d::CCObject *))(*(_QWORD *)v14 + 200LL))(v14); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v30, v16); if ( a4 != 0.0 ) { cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v36, (const struct cocos2d::CCPoint *)v32); if ( (float)-a4 != 0.0 ) { v18 = (float)-a4 * 0.017453292; v19 = *v17; v20 = v30 - *v17; v21 = v17[1]; v22 = v31 - v21; v23 = sinf(v18); v24 = cosf(v18); v30 = (float)((float)(v20 * v24) - (float)(v22 * v23)) + v19; v31 = (float)((float)(v22 * v24) + (float)(v20 * v23)) + v21; } } cocos2d::CCPoint::operator-(&v30, v33, v32); cocos2d::CCPoint::operator*(v33, v34); cocos2d::CCPoint::operator+(a3, v35, v34); cocos2d::CCPoint::operator=(&v30, v35); v25 = &v30; } else { v25 = a3; } (*(void (__fastcall **)(cocos2d::CCParticleSystem *, float *))(*(_QWORD *)v15 + 184LL))(v15, v25); if ( *((_BYTE *)v14 + 817) || *((_BYTE *)v14 + 1800) ) (*(void (__fastcall **)(__int64, struct cocos2d::CCObject *))(*(_QWORD *)a1 + 1336LL))(a1, v14); ParticleGameObject::applyParticleSettings(v14, v15); if ( (*(float (__fastcall **)(cocos2d::CCParticleSystem *))(*(_QWORD *)v15 + 912LL))(v15) < 0.0 ) (*(void (__fastcall **)(cocos2d::CCParticleSystem *))(*(_QWORD *)v15 + 920LL))(v15); v26 = *(_QWORD *)v15; (*(void (__fastcall **)(struct cocos2d::CCObject *))(*(_QWORD *)v14 + 360LL))(v14); (*(void (__fastcall **)(cocos2d::CCParticleSystem *))(v26 + 352))(v15); v27 = *(_QWORD *)v15; (*(void (__fastcall **)(struct cocos2d::CCObject *))(*(_QWORD *)v14 + 128LL))(v14); (*(void (__fastcall **)(cocos2d::CCParticleSystem *))(v27 + 120))(v15); v28 = *(_QWORD *)v15; (*(void (__fastcall **)(struct cocos2d::CCObject *))(*(_QWORD *)v14 + 144LL))(v14); (*(void (__fastcall **)(cocos2d::CCParticleSystem *))(v28 + 136))(v15); LOBYTE(v29) = 1; (*(void (__fastcall **)(struct cocos2d::CCObject *, __int64))(*(_QWORD *)v14 + 336LL))(v14, v29); cocos2d::CCParticleSystem::resumeSystem(v15); } } ++v11; result = cocos2d::CCArray::count(Group); } while ( v11 < result ); } return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source