//
// cocos2d::JniHelper::getClassID from 0x7eda18 to 0x7edb26 (270 bytes)
//
// 3 xrefs:
// > cocos2d::JniHelper::getClassID @ 0x7edb3c
// > cocos2d::JniHelper::getStaticMethodInfo @ 0x7edb6c
// > cocos2d::JniHelper::getMethodInfo @ 0x7edc8c
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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 12:01:01 +0000
//
unsigned int __fastcall cocos2d::JniHelper::getClassID(cocos2d::JniHelper *this, const char *a2, _JNIEnv *a3)
{
unsigned int v4; // r4
int v5; // r5
size_t v6; // r0
char *v7; // r1
char *v8; // r2
int v9; // r0
const char *v11; // [sp+4h] [bp-14h] BYREF
int v12; // [sp+8h] [bp-10h] BYREF
unsigned int v13; // [sp+Ch] [bp-Ch]
void *v14; // [sp+10h] [bp-8h]
v11 = a2;
if ( !a2 && !sub_7ED87C((cocos2d::JniHelper *)&v11) )
return 0;
v4 = (*(int (__fastcall **)(const char *, cocos2d::JniHelper *, _JNIEnv *))(*(_DWORD *)v11 + 24))(v11, this, a3);
if ( !v4 )
{
(*(void (__fastcall **)(const char *))(*(_DWORD *)v11 + 68))(v11);
v5 = (int)v11;
if ( !dword_D2F8F4 || !dword_D2F8F8 )
goto LABEL_23;
v12 = 0;
v13 = 0;
v14 = nullptr;
v6 = strlen((const char *)this);
std::string::__init(&v12, this, v6);
while ( 1 )
{
if ( (v12 & 1) != 0 )
{
v7 = (char *)v14;
if ( v4 >= v13 )
goto LABEL_18;
}
else
{
v7 = (char *)&v12 + 1;
if ( v4 >= (unsigned __int8)v12 >> 1 )
{
LABEL_18:
v9 = (*(int (__fastcall **)(int, char *))(*(_DWORD *)v5 + 668))(v5, v7);
v4 = _JNIEnv::CallObjectMethod(v5, dword_D2F8F4, dword_D2F8F8, v9);
if ( (*(int (__fastcall **)(int))(*(_DWORD *)v5 + 912))(v5) )
{
v4 = 0;
(*(void (__fastcall **)(int))(*(_DWORD *)v5 + 68))(v5);
}
_JNIEnv::DeleteLocalRef(v5);
if ( (v12 & 1) != 0 )
operator delete(v14);
if ( !v4 )
LABEL_23:
_android_log_print(3, "JniHelper", "Failed to find class of %s", (const char *)this);
return v4;
}
}
if ( v7[v4] == 47 )
{
if ( (v12 & 1) != 0 )
v8 = (char *)v14;
else
v8 = (char *)&v12 + 1;
v8[v4] = 46;
}
++v4;
}
}
return v4;
}