//
// cocos2d::CCUserDefault::getBoolForKey from 0xd9071c to 0xd90800 (228 bytes)
//
// 2 xrefs:
// > cocos2d::CCUserDefault::getBoolForKey @ 0xd90804
// > ??> @ 0x71410
//
// 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:08:18 +0000
//
__int64 __fastcall cocos2d::CCUserDefault::getBoolForKey(
cocos2d::CCUserDefault *this,
const char *a2,
unsigned __int8 a3)
{
__int64 v6; // x0
tinyxml2::XMLNode **v7; // x21
__int64 v8; // x0
const char *Str; // x0
_BOOL4 v10; // w20
tinyxml2::XMLDocument *v12; // [xsp+40h] [xbp+40h] BYREF
v12 = nullptr;
v6 = sub_D904E4(a2, &v12);
v7 = (tinyxml2::XMLNode **)v6;
if ( !v6 )
return (unsigned __int8)getBoolForKeyJNI(a2, a3);
v8 = *(_QWORD *)(v6 + 48);
if ( !v8 )
{
sub_D90480((__int64)v12, v7);
return (unsigned __int8)getBoolForKeyJNI(a2, a3);
}
Str = (const char *)tinyxml2::StrPair::GetStr((tinyxml2::StrPair *)(v8 + 24));
v10 = strcmp(Str, "true") == 0;
cocos2d::CCUserDefault::setBoolForKey(this, a2, v10);
cocos2d::CCUserDefault::flush(this);
sub_D90480((__int64)v12, v7);
return v10;
}