//
// cocos2d::CCSprite::draw from 0x100238550 to 0x10023865c (268 bytes)
//
// 72 xrefs:
// > cocos2d::CCTextFieldTTF::draw @ 0x1001cb948
// > cocos2d::CCTextFieldTTF::draw @ 0x1001cb98c
// > ??> @ 0x100763598
// > ??> @ 0x1007736c8
// > ??> @ 0x100774000
// > ??> @ 0x100775168
// > ??> @ 0x100777d18
// > ??> @ 0x10077b4b8
// > ??> @ 0x10077ba58
// > ??> @ 0x100799898
// > ??> @ 0x1007b3260
// > ??> @ 0x1007b8d20
// > ??> @ 0x1007c3e90
// > ??> @ 0x1007c46c8
// > ??> @ 0x1007c75d0
// > ??> @ 0x1007c80b0
// > ??> @ 0x1007c98d0
// > ??> @ 0x1007c9e88
// > ??> @ 0x1007cfb60
// > ??> @ 0x1007d0348
// > ??> @ 0x1007d0b58
// > ??> @ 0x1007e5320
// > ??> @ 0x1007ea348
// > ??> @ 0x1007ea900
// > ??> @ 0x1007ec530
// > ??> @ 0x1007ecab8
// > ??> @ 0x1007ef8e0
// > ??> @ 0x1007f53c8
// > ??> @ 0x1007f5c00
// > ??> @ 0x1007f63f8
// > ??> @ 0x1007f6bf0
// > ??> @ 0x1007f73e8
// > ??> @ 0x1007f7be0
// > ??> @ 0x1007f83d8
// > ??> @ 0x1007f8bd0
// > ??> @ 0x1007f93b8
// > ??> @ 0x1007f9bc8
// > ??> @ 0x1007fa430
// > ??> @ 0x1007fac40
// > ??> @ 0x1007fb450
// > ??> @ 0x1007fbc60
// > ??> @ 0x1007fc470
// > ??> @ 0x1007fcc80
// > ??> @ 0x1007fd490
// > ??> @ 0x1007fdca0
// > ??> @ 0x1007fe4b0
// > ??> @ 0x1007fecc0
// > ??> @ 0x1007ff4e8
// > ??> @ 0x1007ffd40
// > ??> @ 0x100800568
// > ??> @ 0x100800d90
// > ??> @ 0x1008015b8
// > ??> @ 0x100801de0
// > ??> @ 0x1008025f0
// > ??> @ 0x100802e00
// > ??> @ 0x100803610
// > ??> @ 0x100803e20
// > ??> @ 0x100804630
// > ??> @ 0x100804e40
// > ??> @ 0x100805650
// > ??> @ 0x100805e60
// > ??> @ 0x100806670
// > ??> @ 0x100806e80
// > ??> @ 0x100807690
// > ??> @ 0x100807ea0
// > ??> @ 0x1008086b0
// > ??> @ 0x100808ec0
// > ??> @ 0x1008096d0
// > ??> @ 0x100809ee0
// > ??> @ 0x10080ae68
// > ??> @ 0x100810e78
// > ??> @ 0x100816200
//
// 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
//
void __fastcall cocos2d::CCSprite::draw(cocos2d::CCSprite *a1)
{
cocos2d::CCGLProgram *v2; // x0
cocos2d::CCGLProgram *v3; // x0
unsigned int v4; // w0
if ( !a1->m_bDontDraw )
{
if ( a1->_realOpacity )
{
cocos2d::ccGLEnable(a1->m_eGLServerState);
((void (__fastcall *)(cocos2d::CCSprite *))a1->getShaderProgram)(a1);
v2 = (cocos2d::CCGLProgram *)((__int64 (__fastcall *)(cocos2d::CCSprite *))a1->getShaderProgram)(a1);
cocos2d::CCGLProgram::use(v2);
v3 = (cocos2d::CCGLProgram *)((__int64 (__fastcall *)(cocos2d::CCSprite *))a1->getShaderProgram)(a1);
cocos2d::CCGLProgram::setUniformsForBuiltins(v3);
cocos2d::ccGLBlendFunc(a1->m_sBlendFunc.src, a1->m_sBlendFunc.dst);
v4 = ((__int64 (__fastcall *)(cocos2d::CCTexture2D *))a1->m_pobTexture->getName)(a1->m_pobTexture);
cocos2d::ccGLBindTexture2D(v4);
cocos2d::ccGLEnableVertexAttribs(7u);
glVertexAttribPointer(0, 3, 0x1406u, 0, 24, &a1->m_sQuad);
glVertexAttribPointer(2u, 2, 0x1406u, 0, 24, &a1->m_sQuad.tl.texCoords);
glVertexAttribPointer(1u, 4, 0x1401u, 1u, 24, &a1->m_sQuad.tl.colors);
glDrawArrays(5u, 0, 4);
++dword_100885D50;
}
}
}