//
// sub_7691FA from 0x7691fa to 0x76926e (116 bytes)
//
// 3 xrefs:
// > sub_76926E @ 0x76927e
// > sub_76930C @ 0x76935e
// > sub_7693FA @ 0x76945c
//
// 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:59:09 +0000
//
int __fastcall sub_7691FA(int *a1, int *a2, int *a3, int *a4, int a5)
{
int v9; // r0
int v10; // r10
int v11; // r9
int v12; // r4
int v13; // r9
int v14; // r8
int v15; // r6
int v16; // r8
v9 = sub_76916E(a1, a2, a3, a5);
v10 = *a4;
v11 = *a3;
v12 = v9;
if ( sub_7690D8(a5, *a4, *a3) )
{
*a3 = v10;
*a4 = v11;
v13 = *a3;
v14 = *a2;
if ( sub_7690D8(a5, *a3, *a2) )
{
*a2 = v13;
*a3 = v14;
v15 = *a1;
v16 = *a2;
if ( sub_7690D8(a5, *a2, *a1) )
{
v12 += 3;
*a1 = v16;
*a2 = v15;
}
else
{
v12 += 2;
}
}
else
{
++v12;
}
}
return v12;
}