//
// cocos2d::CCParticleSystemQuad::draw from 0x18006c770 to 0x18006c91f (431 bytes)
//
// 14 xrefs:
// > ??> @ 0x180100f10
// > ??> @ 0x180101590
// > ??> @ 0x180101c10
// > ??> @ 0x180102290
// > ??> @ 0x180102910
// > ??> @ 0x180102f90
// > ??> @ 0x180103610
// > ??> @ 0x180103c90
// > ??> @ 0x180104310
// > ??> @ 0x180104990
// > ??> @ 0x180105010
// > ??> @ 0x180106368
// > ??> @ 0x18014cf68
// > ??> @ 0x1801be014
//
// 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:21:55 +0000
//
void __fastcall cocos2d::CCParticleSystemQuad::draw(cocos2d::CCParticleSystemQuad *this, float a2)
{
cocos2d::CCGLProgram *v3; // rax
cocos2d::CCGLProgram *v4; // rax
unsigned int v5; // eax
unsigned int v6; // edx
unsigned int v7; // r8d
unsigned int v8; // edx
__int64 v9; // r9
if ( *((_QWORD *)this + 84) && *((_DWORD *)this + 116) )
{
if ( *((_BYTE *)this + 838) )
{
cocos2d::CCNode::updateTweenActionInt((cocos2d::CCNode *)*((unsigned int *)this + 62), a2);
(*(void (__fastcall **)(cocos2d::CCParticleSystemQuad *))(*(_QWORD *)this + 648LL))(this);
v3 = (cocos2d::CCGLProgram *)(*(__int64 (__fastcall **)(cocos2d::CCParticleSystemQuad *))(*(_QWORD *)this + 648LL))(this);
cocos2d::CCGLProgram::use(v3);
v4 = (cocos2d::CCGLProgram *)(*(__int64 (__fastcall **)(cocos2d::CCParticleSystemQuad *))(*(_QWORD *)this + 648LL))(this);
cocos2d::CCGLProgram::setUniformsForBuiltins(v4);
v5 = (*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 84) + 96LL))(*((_QWORD *)this + 84));
cocos2d::ccGLBindTexture2D((cocos2d *)v5, v6);
cocos2d::ccGLBlendFunc(*((_DWORD *)this + 170), *((_DWORD *)this + 171), v7);
cocos2d::ccGLEnableVertexAttribs((cocos2d *)7, v8);
_glewBindBuffer(34962, *((unsigned int *)this + 202));
_glewVertexAttribPointer(0, 3, 5126, 0, 24, 0);
LOBYTE(v9) = 1;
_glewVertexAttribPointer(1, 4, 5121, v9, 24, 12);
_glewVertexAttribPointer(2, 2, 5126, 0, 24, 16);
_glewBindBuffer(34963, *((unsigned int *)this + 203));
glDrawElements(4u, 6 * *((_DWORD *)this + 109), 0x1403u, nullptr);
_glewBindBuffer(34962, 0);
_glewBindBuffer(34963, 0);
++g_uNumberOfDraws;
}
}
}