//
// sub_100155D50 from 0x100155d50 to 0x100155e08 (184 bytes)
//
// 2 xrefs:
// > BoomScrollLayer::ccTouchCancelled @ 0x100155fb4
// > sub_100155FB8 @ 0x100155fe0
//
// 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:41 +0000
//
__int64 __fastcall sub_100155D50(__int64 result, int a2)
{
__int64 v3; // x20
__int64 v4; // x8
__int64 v5; // x21
float *v6; // x0
float v7; // [xsp+8h] [xbp-38h] BYREF
if ( (a2 & 0x80000000) == 0 )
{
v3 = result;
v4 = 480;
if ( *(_BYTE *)(result + 456) )
v4 = 448;
result = sub_1002E757C(*(_QWORD *)(result + v4));
if ( (int)result > a2 )
{
v5 = *(_QWORD *)(v3 + 504);
v6 = (float *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v3 + 328LL))(v3);
sub_1000262BC(&v7, (float)(*v6 - *(float *)(v3 + 592)) * (float)-a2, 0.0);
result = (*(__int64 (__fastcall **)(__int64, float *))(*(_QWORD *)v5 + 184LL))(v5, &v7);
*(_DWORD *)(v3 + 424) = *(_DWORD *)(v3 + 588);
*(_DWORD *)(v3 + 588) = a2;
}
}
return result;
}