// // cocos2d::CCImage::initWithString from 0xb0d3d0 to 0xb0d748 (888 bytes) // // 1 xrefs: // > @ 0x6a548 // // 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 // __int64 __fastcall cocos2d::CCImage::initWithString( __int64 a1, __int64 a2, unsigned int a3, int a4, unsigned int a5, __int64 a6, int a7) { unsigned __int8 v14; // w0 int StaticMethodInfo; // w1 __int64 result; // x0 cocos2d::CCFileUtils *v17; // x0 unsigned __int64 v18; // x3 void *v19; // x0 __int64 v20; // x22 __int64 v21; // x23 void *v22; // x0 __int64 v23; // x0 __int16 v24; // w1 unsigned int *v25; // x1 int v26; // w2 unsigned int *v27; // x1 int v28; // w2 __int64 v29; // [xsp+30h] [xbp+0h] BYREF void *obj; // [xsp+98h] [xbp+68h] __int64 v31; // [xsp+B0h] [xbp+80h] BYREF __int64 v32; // [xsp+B8h] [xbp+88h] BYREF __int64 v33; // [xsp+C0h] [xbp+90h] BYREF __int64 v34; // [xsp+C8h] [xbp+98h] __int64 v35; // [xsp+D0h] [xbp+A0h] if ( !a2 ) return 0; v14 = atomic_load((unsigned __int8 *)&byte_1245880); if ( (v14 & 1) == 0 && _cxa_guard_acquire((__guard *)&byte_1245880) ) { obj = &dword_1245888; dword_1245888 = 0; dword_124588C = 0; qword_1245890 = 0; _cxa_guard_release((__guard *)&byte_1245880); __cxa_atexit((void (*)(void *))cocos2d::BitmapDC::~BitmapDC, &dword_1245888, &unk_122F000); } StaticMethodInfo = (unsigned __int8)cocos2d::JniHelper::getStaticMethodInfo( &v33, "org/cocos2dx/lib/Cocos2dxBitmap", "createTextBitmapShadowStroke", "(Ljava/lang/String;Ljava/lang/String;IFFFIIIZFFFZFFFF)V"); result = 0; if ( StaticMethodInfo ) { v17 = cocos2d::CCFileUtils::sharedFileUtils(); ((void (__fastcall *)(__int64 *__return_ptr, cocos2d::CCFileUtils *, __int64, _QWORD))v17->createCCArrayWithContentsOfFile)( &v31, v17, a6, 0); if ( !sub_D1641C((unsigned int)&v29 + 128, "assets/") ) { v18 = *(_QWORD *)(v31 - 24); if ( v18 <= 6 ) sub_D13C5C("%s: __pos (which is %zu) > this->size() (which is %zu)", "basic_string::substr", 7u, v18); obj = &v32; sub_D14F84(&v32, &v31, 7, -1); sub_D163D4(&v31, obj); v19 = (void *)(v32 - 24); if ( (__int64 *)(v32 - 24) != &qword_124B6B0 ) { if ( &pthread_create ) { v25 = (unsigned int *)(v32 - 8); do v26 = __ldaxr(v25); while ( __stlxr(v26 - 1, v25) ); } else { v26 = *(_DWORD *)(v32 - 8); *(_DWORD *)(v32 - 8) = v26 - 1; } if ( v26 <= 0 ) operator delete(v19); } } v20 = (*(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v33 + 1336LL))(v33, a2); v21 = (*(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v33 + 1336LL))(v33, v31); _JNIEnv::CallStaticVoidMethod( v33, v34, v35, v20, v21, (unsigned int)(int)(float)a7, a5, a3, 1.0, 1.0, 1.0, 0.0, -0.0, 0.0, 0.0, 0.0, a4, 0, 0, 0, 0); (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v33 + 184LL))(v33, v20); (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v33 + 184LL))(v33, v21); (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v33 + 184LL))(v33, v34); v22 = (void *)(v31 - 24); if ( (__int64 *)(v31 - 24) != &qword_124B6B0 ) { if ( &pthread_create ) { v27 = (unsigned int *)(v31 - 8); do v28 = __ldaxr(v27); while ( __stlxr(v28 - 1, v27) ); } else { v28 = *(_DWORD *)(v31 - 8); *(_DWORD *)(v31 - 8) = v28 - 1; } if ( v28 <= 0 ) operator delete(v22); } v23 = qword_1245890; *(_QWORD *)(a1 + 64) = qword_1245890; if ( v23 ) { v24 = dword_124588C; *(_WORD *)(a1 + 56) = dword_1245888; *(_WORD *)(a1 + 58) = v24; *(_BYTE *)(a1 + 72) = 1; *(_BYTE *)(a1 + 73) = 1; *(_DWORD *)(a1 + 60) = 8; return 1; } return 0; } return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source