//
// nextRemapStateForTrigger from 0x46d0d0 to 0x46d188 (184 bytes)
//
// 1 xrefs:
// > processTraceOutSource @ 0x47cf7e
//
// 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:49:01 +0000
//
int __fastcall nextRemapStateForTrigger(_DWORD *a1, int a2, int a3)
{
unsigned int *v6; // r8
unsigned int *i; // r4
_DWORD *v8; // r0
_DWORD *v9; // r0
unsigned int v10; // r2
unsigned int v11; // r1
_DWORD *v12; // r0
unsigned int v14; // [sp+4h] [bp-10h] BYREF
unsigned int v15; // [sp+8h] [bp-Ch] BYREF
if ( a1[223] != 1268 || a1[412] == a1[413] )
return a2;
if ( a3 != a2 )
{
*(_DWORD *)(a3 + 16) = *(_DWORD *)(a2 + 16);
std::__hash_table,std::__unordered_map_hasher,std::hash,true>,std::__unordered_map_equal,std::equal_to,true>,std::allocator>>::__assign_multi,void *> *>>(
(_DWORD *)a3,
*(_DWORD **)(a2 + 8),
nullptr);
}
*(_QWORD *)(a3 + 24) = *(_QWORD *)(a2 + 24);
v6 = (unsigned int *)a1[413];
for ( i = (unsigned int *)a1[412]; i != v6; i += 4 )
{
v14 = *i;
v15 = i[2];
v8 = std::__hash_table,std::__unordered_map_hasher,std::hash,true>,std::__unordered_map_equal,std::equal_to,true>,std::allocator>>::find(
(_DWORD *)a3,
&v15);
if ( v8 )
v15 = v8[3];
v9 = *(_DWORD **)(a3 + 8);
v10 = v14;
v11 = v15;
while ( v9 )
{
if ( v9[3] == v10 )
v9[3] = v11;
v9 = (_DWORD *)*v9;
}
v12 = std::unordered_map::operator[](a3, &v14);
*v12 = v15;
}
*(_QWORD *)(a3 + 24) = hashRemapMap(a3);
return a3;
}