//
// LevelSearchLayer::toggleTime from 0x10005418c to 0x100054290 (260 bytes)
//
// 1 xrefs:
// > LevelSearchLayer::init @ 0x100052af0
//
// 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
//
void __fastcall LevelSearchLayer::toggleTime(LevelSearchLayer *a1, cocos2d::CCObject *a2)
{
__int64 v3; // x19
_BOOL4 v4; // w0
bool v5; // w22
bool v6; // w20
cocos2d::CCDictionary *m_difficultyDict; // x23
__int64 v8; // x24
cocos2d::CCString *v9; // x0
char *CString; // x0
__int64 v11; // x0
__int16 v12; // w8
GameLevelManager *v13; // x0
void *__p[2]; // [xsp+8h] [xbp-48h] BYREF
char v15; // [xsp+1Fh] [xbp-31h]
v3 = ((__int64 (__fastcall *)(cocos2d::CCObject *))a2->getTag)(a2);
v4 = LevelSearchLayer::checkTime(a1, v3);
v5 = v4;
v6 = !v4;
m_difficultyDict = a1->m_difficultyDict;
v8 = sub_100268F4C("%i", !v4);
v9 = (cocos2d::CCString *)sub_100268F4C("T%i", v3);
CString = (char *)cocos2d::CCString::getCString(v9);
sub_100009900(__p, CString);
cocos2d::CCDictionary::setObject_1(m_difficultyDict, v8, __p);
if ( v15 < 0 )
operator delete(__p[0]);
v11 = sub_10024A388(a1->m_lengthSprites, v3);
if ( v5 )
{
BYTE2(__p[0]) = 125;
v12 = 32125;
}
else
{
BYTE2(__p[0]) = -1;
v12 = -1;
}
LOWORD(__p[0]) = v12;
(*(void (__fastcall **)(__int64, void **))(*(_QWORD *)v11 + 1056LL))(v11, __p);
v13 = GameLevelManager::sharedState();
GameLevelManager::setLenVal(v13, v3, v6);
}