//
// cocos2d::CCDrawNode::init from 0x100045c9c to 0x100045da4 (264 bytes)
//
// 2 xrefs:
// > HardStreak::init @ 0x100065fb0
// > ??> @ 0x1008bae18
//
// 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 10:57:38 +0000
//
__int64 __fastcall cocos2d::CCDrawNode::init(GLuint *a1)
{
__int64 v2; // x0
__int64 v3; // x0
*((_QWORD *)a1 + 46) = 0x30300000001LL;
v2 = cocos2d::CCShaderCache::sharedShaderCache();
v3 = cocos2d::CCShaderCache::programForKey(v2, "ShaderPositionColor");
(*(void (__fastcall **)(GLuint *, __int64))(*(_QWORD *)a1 + 664LL))(a1, v3);
cocos2d::CCDrawNode::ensureCapacity(a1, 0x200u);
glGenVertexArraysOES(1, a1 + 85);
cocos2d::ccGLBindVAO(a1[85]);
glGenBuffers(1, a1 + 86);
glBindBuffer(0x8892u, a1[86]);
glBufferData(0x8892u, 20LL * a1[87], *((const GLvoid **)a1 + 45), 0x88E0u);
glEnableVertexAttribArray(0);
glVertexAttribPointer(0, 2, 0x1406u, 0, 20, nullptr);
glEnableVertexAttribArray(1u);
glVertexAttribPointer(1u, 4, 0x1401u, 1u, 20, (const GLvoid *)8);
glBindBuffer(0x8892u, 0);
cocos2d::ccGLBindVAO(0);
*((_BYTE *)a1 + 376) = 1;
return 1;
}