//
// ControllerInputNode::onButton from 0x765320 to 0x765370 (80 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:59:07 +0000
//
int __fastcall ControllerInputNode::onButton(ControllerInputNode *this, cocos2d::CCObject *a2)
{
int v3; // r4
int result; // r0
int v5; // r5
int (__fastcall *v6)(int, int); // r6
int v7; // r0
v3 = *((_DWORD *)&unk_C74AD4 + 7 * (*(int (__fastcall **)(cocos2d::CCObject *))(*(_DWORD *)a2 + 32))(a2));
*((_DWORD *)this + 68) = v3;
result = ControllerInputNode::refreshVisuals(this);
if ( *((_BYTE *)this + 268) && (v3 & 1) != 0 )
LOWORD(v3) = v3 + 1;
v5 = *((_DWORD *)this + 66);
if ( v5 )
{
v6 = *(int (__fastcall **)(int, int))(*(_DWORD *)v5 + 8);
v7 = GJKeybindManager::encodeChord(v3, 0, 0, 0);
return v6(v5, v7);
}
return result;
}