// // ParticlePreviewLayer::draw from 0xafcb08 to 0xafd01c (1300 bytes) // // 2 xrefs: // > @ 0x494e0 // > @ 0x14b0868 // // This function is hookable on this platform (idp: arm, 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 13:01:18 +0000 // __int64 __fastcall ParticlePreviewLayer::draw(ParticlePreviewLayer *this) { unsigned __int8 v2; // w4 int v3; // w1 int v4; // w0 _BOOL4 v5; // w22 float v6; // s9 unsigned __int8 v7; // w4 float v8; // s8 unsigned __int8 v9; // w4 cocos2d *v10; // x0 float v11; // s1 bool v12; // w3 cocos2d *v13; // x0 float v14; // s1 bool v15; // w3 _BOOL4 v17; // w21 const cocos2d::CCPoint *v18; // x0 float v19; // s8 float v20; // s9 float v21; // s11 float v22; // s0 const cocos2d::CCPoint *v23; // x2 float v24; // s2 cocos2d *v25; // x0 bool v26; // w3 __int64 v27; // x27 __int64 v28; // x0 __int64 v29; // x27 const cocos2d::CCPoint *v30; // x0 __int64 v31; // x0 const cocos2d::CCPoint *v32; // x2 float v33; // s0 float v34; // s0 float v35; // [xsp+80h] [xbp+80h] float v36; // [xsp+80h] [xbp+80h] float v37; // [xsp+80h] [xbp+80h] __int64 v38; // [xsp+98h] [xbp+98h] BYREF __int64 v39; // [xsp+A0h] [xbp+A0h] BYREF _BYTE v40[8]; // [xsp+A8h] [xbp+A8h] BYREF __int64 v41; // [xsp+B0h] [xbp+B0h] BYREF cocos2d::CCLayerColor::draw(this); v3 = *((_DWORD *)this + 136); v4 = *((_DWORD *)this + 137); if ( v3 == 1 ) { v5 = v4 == 2; v17 = v4 == 3; if ( !*((_BYTE *)this + 560) ) goto LABEL_5; LABEL_25: cocos2d::ccDrawColor4B(nullptr, 0xFFu, 0, 0xFFu, v2); v27 = (*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 192LL))(*((_QWORD *)this + 69)); v28 = (*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 952LL))(*((_QWORD *)this + 69)); cocos2d::CCPoint::operator-(&v41, v28); cocos2d::CCPoint::operator+(&v38, v27); v29 = (*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 192LL))(*((_QWORD *)this + 69)); (*(void (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 952LL))(*((_QWORD *)this + 69)); cocos2d::CCPoint::operator+(&v39, v29); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v40, (const cocos2d::CCPoint *)&v38); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v41, (const cocos2d::CCPoint *)&v39); cocos2d::ccDrawRect(v40, &v41); if ( v5 ) { LABEL_26: cocos2d::ccDrawColor4B(nullptr, 0xFFu, 0xFFu, 0xFFu, v2); v30 = (const cocos2d::CCPoint *)(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 192LL))(*((_QWORD *)this + 69)); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v39, v30); v31 = (*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 1040LL))(*((_QWORD *)this + 69)); cocos2d::CCPoint::operator*(v31, 0.1); cocos2d::CCPoint::operator+(&v41, &v39); cocos2d::ccDrawLine((cocos2d *)&v39, (const cocos2d::CCPoint *)&v41, v32); if ( !v17 ) return _stack_chk_guard; LABEL_17: cocos2d::ccDrawColor4B((cocos2d *)0xFFFFFFFFLL, 0xFFu, 0, 0xFFu, v2); v18 = (const cocos2d::CCPoint *)(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 192LL))(*((_QWORD *)this + 69)); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v39, v18); v19 = (*(float (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 1056LL))(*((_QWORD *)this + 69)) * 0.25; v20 = (*(float (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 1000LL))(*((_QWORD *)this + 69)) * 0.017453; v21 = sinf(v20); v22 = cosf(v20); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v40, v19 * v22, v19 * v21); cocos2d::CCPoint::operator+(&v41, &v39); cocos2d::ccDrawLine((cocos2d *)&v39, (const cocos2d::CCPoint *)&v41, v23); if ( fabsf((*(float (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 1016LL))(*((_QWORD *)this + 69))) < 180.0 ) { v34 = fabsf((*(float (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 1016LL))(*((_QWORD *)this + 69))); v24 = (float)(v34 * 0.017453) + (float)(v34 * 0.017453); } else { v24 = 6.2832; } v37 = v24; v25 = (cocos2d *)(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 192LL))(*((_QWORD *)this + 69)); cocos2d::ccDrawCircleSegment( v25, (const cocos2d::CCPoint *)&dword_14, 20.0, v20 - (float)(v37 * 0.5), v37, 0, v26, 1.0, 1.0); return _stack_chk_guard; } LABEL_16: if ( !v17 ) return _stack_chk_guard; goto LABEL_17; } if ( v3 == 2 ) { v17 = v4 == 3; if ( !*((_BYTE *)this + 560) ) goto LABEL_5; v5 = 1; LABEL_14: if ( v4 == 1 ) goto LABEL_25; goto LABEL_15; } v5 = v4 == 2; if ( v3 != 3 ) { v17 = v4 == 3; if ( !*((_BYTE *)this + 560) ) { if ( !v5 && v4 != 1 && v4 != 3 ) return _stack_chk_guard; goto LABEL_5; } goto LABEL_14; } if ( *((_BYTE *)this + 560) ) { v17 = 1; if ( v4 == 1 ) goto LABEL_25; LABEL_15: if ( v5 ) goto LABEL_26; goto LABEL_16; } LABEL_5: v6 = (float)-(*(float (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 1000LL))(*((_QWORD *)this + 69)) * 0.017453; if ( fabsf((*(float (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 1016LL))(*((_QWORD *)this + 69))) < 180.0 ) { v33 = fabsf((*(float (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 1016LL))(*((_QWORD *)this + 69))); v8 = (float)(v33 * 0.017453) + (float)(v33 * 0.017453); } else { v8 = 6.2832; } cocos2d::ccDrawColor4B(nullptr, 0xFFu, 0, 0xFFu, v7); v35 = COERCE_FLOAT(COERCE_UNSIGNED_INT128(((long double (__fastcall *)(_QWORD))*(_QWORD *)(**((_QWORD **)this + 69) + 1168LL))(*((_QWORD *)this + 69)))); if ( v35 > 0.0 ) { v10 = (cocos2d *)(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 192LL))(*((_QWORD *)this + 69)); v11 = (float)-(float)(v6 + (float)(v8 * 0.5)) + 3.14159265; cocos2d::ccDrawCircleSegment(v10, (const cocos2d::CCPoint *)((char *)&qword_20 + 4), v35, v11, v8, 0, v12, 1.0, 1.0); } cocos2d::ccDrawColor4B((cocos2d *)0xFFFFFFFFLL, 0x96u, 0, 0xFFu, v9); v36 = COERCE_FLOAT(COERCE_UNSIGNED_INT128(((long double (__fastcall *)(_QWORD))*(_QWORD *)(**((_QWORD **)this + 69) + 1200LL))(*((_QWORD *)this + 69)))); if ( v36 > 0.0 ) { v13 = (cocos2d *)(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 69) + 192LL))(*((_QWORD *)this + 69)); v14 = (float)-(float)(v6 + (float)(v8 * 0.5)) + 3.14159265; cocos2d::ccDrawCircleSegment(v13, (const cocos2d::CCPoint *)((char *)&qword_20 + 4), v36, v14, v8, 0, v15, 1.0, 1.0); } return _stack_chk_guard; }
GD Web Decomp Icon

GD Web Decomp

Raw Source