//
// EndTriggerGameObject::triggerObject from 0x1404bccd0 to 0x1404bcdbd (237 bytes)
//
// 2 xrefs:
// > ??> @ 0x140618148
// > ??> @ 0x1406dce00
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
// Hidden C++ exception states: #wind=2
void EndTriggerGameObject::triggerObject(
EndTriggerGameObject *a1,
GJBaseGameLayer *a2,
int a3,
std::vector *const a4)
{
const std::vector *v6; // r8
char v7; // bl
void *v8; // rcx
void *Block[2]; // [rsp+20h] [rbp-38h] BYREF
__int64 v10; // [rsp+30h] [rbp-28h]
_QWORD v11[4]; // [rsp+38h] [rbp-20h] BYREF
if ( a4 )
{
v6 = (const std::vector *)sub_14024B270(v11, (__int64)a4);
v7 = 1;
}
else
{
*(_OWORD *)Block = 0;
v10 = 0;
v6 = (const std::vector *)Block;
v7 = 2;
}
a2->activatePlatformerEndTrigger(a2, a1, v6);
if ( (v7 & 2) != 0 )
{
v7 &= ~2u;
v8 = Block[0];
if ( Block[0] )
{
if ( (unsigned __int64)(4 * ((signed __int64)(v10 - (unsigned __int64)Block[0]) >> 2)) >= 0x1000 )
{
v8 = *((void **)Block[0] - 1);
if ( (unsigned __int64)((char *)Block[0] - (char *)v8 - 8) > 0x1F )
invalid_parameter_noinfo_noreturn();
}
j_j_free(v8);
*(_OWORD *)Block = 0;
v10 = 0;
}
}
if ( (v7 & 1) != 0 )
sub_14005E430((__int64)v11);
}