//
// cocos2d::CCTMXLayer::vertexZForPos from 0x1800b1040 to 0x1800b10b3 (115 bytes)
//
// 4 xrefs:
// > cocos2d::CCTMXLayer::setupTileSprite @ 0x1800b089b
// > cocos2d::CCTMXLayer::tileAt @ 0x1800b0db0
// > ??> @ 0x18014cf68
// > ??> @ 0x1801c2550
//
// 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 11:22:19 +0000
//
__int64 __fastcall cocos2d::CCTMXLayer::vertexZForPos(cocos2d::CCTMXLayer *this, const struct cocos2d::CCPoint *a2)
{
int v2; // eax
if ( !*((_BYTE *)this + 456) )
return *((unsigned int *)this + 113);
v2 = *((_DWORD *)this + 98);
if ( !v2 )
return (unsigned int)(int)(float)-(float)(*((float *)this + 91) - *((float *)a2 + 1));
if ( v2 == 2 )
return (unsigned int)(int)(float)-(float)((float)(int)(float)(*((float *)this + 91) + *((float *)this + 90))
- (float)(*((float *)a2 + 1) + *(float *)a2));
return 0;
}