//
// PlayLayer::updateTimeLabel from 0x100147424 to 0x100147590 (364 bytes)
//
// 1 xrefs:
// > ??> @ 0x1008dfa20
//
// 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:59:34 +0000
//
void __fastcall PlayLayer::updateTimeLabel(__int64 a1, __int64 a2, int a3, int a4)
{
__int64 v8; // x0
const std::string::value_type *CString; // x0
void **v10; // x1
std::string *v11; // x1
__int64 v12; // x0
__int64 v13; // x0
__int64 v14; // x19
float v15; // s8
std::string::size_type v16; // x20
std::string::size_type size; // x21
__int64 v18; // x0
std::string::size_type v19; // x8
float v20; // [xsp+18h] [xbp-68h] BYREF
void *__p[2]; // [xsp+20h] [xbp-60h] BYREF
char v22; // [xsp+37h] [xbp-49h]
std::string v23; // [xsp+38h] [xbp-48h] BYREF
if ( (*(unsigned int (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 14336) + 352LL))(*(_QWORD *)(a1 + 14336))
&& *(_BYTE *)(a1 + 12238) == 1 )
{
memset(&v23, 0, sizeof(v23));
if ( a4 )
{
v8 = sub_1003065B0("%i.%02d", a2, a3);
CString = (const std::string::value_type *)cocos2d::CCString::getCString(v8);
std::string::assign(&v23, CString);
}
else
{
GameToolbox::intToString(a2, __p);
if ( v22 >= 0 )
v10 = __p;
else
v10 = (void **)__p[0];
std::string::assign(&v23, (const std::string::value_type *)v10);
if ( v22 < 0 )
operator delete(__p[0]);
}
if ( (v23.__r_.__value_.__r.__words[2] & 0x8000000000000000LL) == 0LL )
v11 = &v23;
else
v11 = (std::string *)v23.__r_.__value_.__r.__words[0];
v12 = (*(__int64 (__fastcall **)(_QWORD, std::string *))(**(_QWORD **)(a1 + 14336) + 928LL))(
*(_QWORD *)(a1 + 14336),
v11);
v13 = cocos2d::CCDirector::sharedDirector(v12);
cocos2d::CCDirector::getWinSize(__p, v13);
v14 = *(_QWORD *)(a1 + 14336);
v15 = *(float *)__p;
v16 = HIBYTE(v23.__r_.__value_.__r.__words[2]);
size = v23.__r_.__value_.__l.__size_;
v18 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v14 + 192LL))(v14);
if ( (v16 & 0x80u) == 0LL )
v19 = v16;
else
v19 = size;
sub_1000262BC(&v20, (float)(v15 * 0.5) - (float)(5 * v19), *(float *)(v18 + 4));
(*(void (__fastcall **)(__int64, float *))(*(_QWORD *)v14 + 184LL))(v14, &v20);
if ( SHIBYTE(v23.__r_.__value_.__r.__words[2]) < 0 )
operator delete(v23.__r_.__value_.__l.__data_);
}
}