//
// sub_100114810 from 0x100114810 to 0x100114906 (246 bytes)
//
// 2 xrefs:
// > GJBaseGameLayer::controlTriggersInGroup @ 0x100113ef6
// > GJBaseGameLayer::controlTriggersWithControlID @ 0x100114977
//
// This function is hookable on this platform (idp: pc, 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 12:24:33 +0000
//
__int64 __fastcall sub_100114810(__int64 a1, __int64 a2, int a3, int a4)
{
__int64 result; // rax
__int64 v5; // rdi
result = *(_QWORD *)(a1 + 1672);
v5 = *(_QWORD *)(a1 + 1680);
if ( result != v5 )
{
if ( a3 == -1 )
{
if ( a4 )
{
if ( a4 == 1 )
{
do
{
if ( *(_QWORD *)result == a2 )
*(_WORD *)(result + 78) = 257;
result += 96;
}
while ( result != v5 );
}
else if ( a4 == 2 )
{
do
{
if ( *(_QWORD *)result == a2 )
*(_WORD *)(result + 78) = 0;
result += 96;
}
while ( result != v5 );
}
}
else
{
do
{
if ( *(_QWORD *)result == a2 )
*(_BYTE *)(result + 77) = 1;
result += 96;
}
while ( result != v5 );
}
}
else if ( a4 )
{
if ( a4 == 1 )
{
do
{
if ( *(_DWORD *)(result + 80) == a3 )
*(_WORD *)(result + 78) = 257;
result += 96;
}
while ( result != v5 );
}
else if ( a4 == 2 )
{
do
{
if ( *(_DWORD *)(result + 80) == a3 )
*(_WORD *)(result + 78) = 0;
result += 96;
}
while ( result != v5 );
}
}
else
{
do
{
if ( *(_DWORD *)(result + 80) == a3 )
*(_BYTE *)(result + 77) = 1;
result += 96;
}
while ( result != v5 );
}
}
return result;
}