//
// GJGameLevel::dtExpandOrder from 0x1000d0838 to 0x1000d0934 (252 bytes)
//
// 21 xrefs:
// > GJGameLevel::getSessionBest @ 0x1000d0b70
// > sub_1000D0EA4 @ 0x1000d0f44
// > DeathTrackerPopup::init @ 0x1004b9ae8
// > sub_1004BB048 @ 0x1004bb0fc
// > sub_1004BB780 @ 0x1004bb854
// > sub_1004BBCDC @ 0x1004bbe68
// > sub_1004BBCDC @ 0x1004bbebc
// > sub_1004BBCDC @ 0x1004bbee0
// > sub_1004BBCDC @ 0x1004bbf6c
// > sub_1004BCF20 @ 0x1004bcf84
// > sub_1004BCF20 @ 0x1004bcffc
// > sub_1004BCF20 @ 0x1004bd0b8
// > sub_1004BCF20 @ 0x1004bd134
// > sub_1004BE380 @ 0x1004be3e8
// > sub_1004BE380 @ 0x1004be470
// > sub_1004BE5CC @ 0x1004be6d8
// > sub_1004BE5CC @ 0x1004be6ec
// > sub_1004BEB94 @ 0x1004befbc
// > sub_1004BEB94 @ 0x1004bf034
// > sub_1004BEB94 @ 0x1004bf104
// > sub_1004BEB94 @ 0x1004bf154
//
// 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:58:53 +0000
//
void __fastcall GJGameLevel::dtExpandOrder(std::string *this, __int64 a2)
{
std::string::size_type size; // x23
std::string::size_type v5; // x21
std::string::size_type v6; // x0
std::string::size_type v7; // x24
const char *v8; // x22
std::string *v9; // x25
int v10; // w21
int v11; // [xsp+Ch] [xbp-44h] BYREF
if ( (this->__r_.__value_.__r.__words[2] & 0x8000000000000000LL) == 0LL )
size = HIBYTE(this->__r_.__value_.__r.__words[2]);
else
size = this->__r_.__value_.__l.__size_;
if ( size )
{
v5 = 0;
while ( 1 )
{
v6 = std::string::find(this, 44, v5);
v7 = v6 == -1 ? size : v6;
if ( SHIBYTE(this->__r_.__value_.__r.__words[2]) < 0 )
{
v9 = (std::string *)this->__r_.__value_.__r.__words[0];
v8 = (const char *)memchr((void *)(this->__r_.__value_.__r.__words[0] + v5), 120, v7 - v5);
}
else
{
v8 = (const char *)memchr((char *)this + v5, 120, v7 - v5);
v9 = this;
}
v11 = atoi((const char *)v9 + v5);
if ( !v8 )
break;
v10 = atoi(v8 + 1);
if ( v10 >= 1 )
goto LABEL_16;
LABEL_17:
v5 = v7 + 1;
if ( v7 + 1 >= size )
return;
}
v10 = 1;
do
{
LABEL_16:
sub_10000D038(a2, &v11);
--v10;
}
while ( v10 );
goto LABEL_17;
}
}