//
// EditorUI::findSnapObject from 0x7c785c to 0x7c7998 (316 bytes)
//
// 3 xrefs:
// > EditorUI::startFreeMoveTouch @ 0xbd5170
// > EditorUI::startFreeMoveTouch @ 0xbd51a8
// > ??> @ 0xb4928
//
// This function is hookable on this platform (idp: arm, 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:54:09 +0000
//
__int64 __fastcall EditorUI::findSnapObject(GameObject **a1, const cocos2d::CCPoint *a2, float a3)
{
cocos2d::CCArray *v6; // x0
cocos2d::CCArray *v7; // x26
unsigned int i; // w20
GameObject *v9; // x21
_BYTE v11[24]; // [xsp+60h] [xbp+60h] BYREF
_BYTE v12[16]; // [xsp+78h] [xbp+78h] BYREF
v6 = (cocos2d::CCArray *)cocos2d::CCArray::count(a1[112]);
if ( (_DWORD)v6 )
{
v7 = (cocos2d::CCArray *)cocos2d::CCArray::create(v6);
for ( i = 0; i < (unsigned int)cocos2d::CCArray::count(a1[112]); ++i )
{
v9 = (GameObject *)cocos2d::CCArray::objectAtIndex(a1[112], i);
LevelEditorLayer::getObjectRect(a1[180], v9, 0, 0, (cocos2d::CCRect *)v11);
LevelEditorLayer::getObjectRect(a1[180], v9, 0, 0, (cocos2d::CCRect *)v12);
if ( (unsigned __int8)cocos2d::CCRect::containsPoint((cocos2d::CCRect *)v12, a2) )
cocos2d::CCArray::addObject(v7, v9);
}
EditorUI::findSnapObject(a1, v7, a3);
}
else
{
EditorUI::findSnapObject(a1, nullptr, a3);
}
return _stack_chk_guard;
}