// // LevelSearchLayer::toggleDifficulty from 0x10005c59c to 0x10005c808 (620 bytes) // // 1 xrefs: // > LevelSearchLayer::init @ 0x10005af64 // // 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 10:57:48 +0000 // __int64 __fastcall LevelSearchLayer::toggleDifficulty(__int64 a1, __int64 a2) { __int64 v3; // x20 int v4; // w22 __int64 v5; // x21 __int64 v6; // x21 __int64 v7; // x23 __int64 v8; // x24 __int64 v9; // x0 char *CString; // x0 __int64 v11; // x0 __int64 v12; // x0 __int64 v13; // x0 __int64 v14; // x20 __int64 v15; // x0 char *v16; // x0 __int64 v17; // x0 __int64 v18; // x20 __int64 v20; // x22 __int64 v21; // x22 __int64 v22; // x22 void *__p[2]; // [xsp+8h] [xbp-48h] BYREF char v24; // [xsp+1Fh] [xbp-31h] v3 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a2 + 64LL))(a2); v4 = LevelSearchLayer::checkDiff(a1, v3); if ( *(_DWORD *)(a1 + 432) == 1 ) { v5 = 0; do { if ( (_DWORD)v3 != (_DWORD)v5 ) sub_10005CBA8(a1, v5, 0); v5 = (unsigned int)(v5 + 1); } while ( (_DWORD)v5 != 8 ); } v6 = v4 ^ 1u; v7 = *(_QWORD *)(a1 + 480); v8 = sub_1003065B0("%i", v4 ^ 1u); v9 = sub_1003065B0("D%i", v3); CString = (char *)cocos2d::CCString::getCString(v9); sub_100009900(__p, CString); cocos2d::CCDictionary::setObject(v7, v8, __p); if ( v24 < 0 ) operator delete(__p[0]); v11 = sub_1002E75A0(*(_QWORD *)(a1 + 464), v3); if ( (v4 & 1) != 0 ) { memset(__p, 125, 3); (*(void (__fastcall **)(__int64, void **))(*(_QWORD *)v11 + 960LL))(v11, __p); goto LABEL_10; } BYTE2(__p[0]) = -1; LOWORD(__p[0]) = -1; (*(void (__fastcall **)(__int64, void **))(*(_QWORD *)v11 + 960LL))(v11, __p); if ( (_DWORD)v3 ) { if ( (_DWORD)v3 == 6 ) { v21 = 0; do { sub_10005CBA8(a1, v21, 0); v21 = (unsigned int)(v21 + 1); } while ( (_DWORD)v21 != 6 ); goto LABEL_11; } if ( (_DWORD)v3 != 7 ) { LABEL_10: sub_10005CBA8(a1, 0, 0); sub_10005CBA8(a1, 6, 0); LABEL_11: v12 = sub_10005CBA8(a1, 7, 0); goto LABEL_12; } v20 = 0; do { v12 = sub_10005CBA8(a1, v20, 0); v20 = (unsigned int)(v20 + 1); } while ( (_DWORD)v20 != 7 ); } else { v22 = 1; do { v12 = sub_10005CBA8(a1, v22, 0); v22 = (unsigned int)(v22 + 1); } while ( (_DWORD)v22 != 8 ); } LABEL_12: v13 = GameLevelManager::sharedState(v12); sub_1000CDB10(v13, v3, v6); v14 = *(_QWORD *)(a1 + 480); v15 = sub_1003065B0("D%i", 6); v16 = (char *)cocos2d::CCString::getCString(v15); sub_100009900(__p, v16); v17 = cocos2d::CCDictionary::valueForKey(v14, __p); v18 = cocos2d::CCString::boolValue(v17); if ( v24 < 0 ) operator delete(__p[0]); (*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 496) + 1056LL))(*(_QWORD *)(a1 + 496), v18); return (*(__int64 (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 496) + 344LL))(*(_QWORD *)(a1 + 496), v18); }
GD Web Decomp Icon

GD Web Decomp

Raw Source