//
// SetupSpawnPopup::onSelectRemap from 0x5eab8c to 0x5eac4c (192 bytes)
//
// 0 xrefs:
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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 11:54:22 +0000
//
unsigned __int8 *__fastcall SetupSpawnPopup::onSelectRemap(unsigned __int8 *this, cocos2d::CCObject *a2)
{
unsigned __int8 *v2; // r4
int v3; // r5
unsigned int v4; // r0
int v5; // r3
std::logic_error *exception; // r4
int v7; // r2
int v8; // r1
v2 = this;
v3 = *(this + 712);
if ( !*(this + 712) )
{
v4 = (*(int (__fastcall **)(cocos2d::CCObject *))(*(_DWORD *)a2 + 32))(a2);
v5 = *((_DWORD *)v2 + 180);
if ( v4 >= (*((_DWORD *)v2 + 181) - v5) >> 3 )
{
exception = (std::logic_error *)_cxa_allocate_exception(8u);
std::logic_error::logic_error(exception, "vector");
*(_DWORD *)exception = &off_D1548C;
_cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::out_of_range,
(void (*)(void *))std::length_error::~length_error);
}
v7 = *(_DWORD *)(v5 + 8 * v4);
v8 = v5 + 8 * v4;
if ( *((_DWORD *)v2 + 183) == v7 && *((_DWORD *)v2 + 184) == *(_DWORD *)(v8 + 4) )
{
*((_DWORD *)v2 + 183) = v3;
*((_DWORD *)v2 + 184) = v3;
}
else
{
*((_DWORD *)v2 + 183) = v7;
*((_DWORD *)v2 + 184) = *(_DWORD *)(v8 + 4);
SetupTriggerPopup::updateValue((SetupTriggerPopup *)v2, -1, (float)v7);
SetupTriggerPopup::updateValue((SetupTriggerPopup *)v2, -2, (float)*((int *)v2 + 184));
}
return SetupSpawnPopup::queueUpdateButtons(v2);
}
return this;
}