//
// cocos2d::CCTMXLayer::atlasIndexForExistantZ from 0xdab12c to 0xdab1a0 (116 bytes)
//
// 4 xrefs:
// > cocos2d::CCTMXLayer::updateTileForGID @ 0xdabfa0
// > cocos2d::CCTMXLayer::tileAt @ 0xdac4c4
// > cocos2d::CCTMXLayer::removeTileAt @ 0xdac5b0
// > ??> @ 0x1053a0
//
// 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 13:08:34 +0000
//
unsigned __int64 __fastcall cocos2d::CCTMXLayer::atlasIndexForExistantZ(cocos2d::CCTMXLayer *this, int a2)
{
int v3; // [xsp+24h] [xbp+24h] BYREF
v3 = a2;
return ((unsigned __int64)bsearch(
&v3,
*(const void **)(*((_QWORD *)this + 58) + 16LL),
**((unsigned int **)this + 58),
8u,
(int (*)(const void *, const void *))sub_DAAC24)
- *(_QWORD *)(*((_QWORD *)this + 58) + 16LL)) >> 3;
}