// // cocos2d::ccDrawCubicBezier from 0xad8c44 to 0xad8e2c (488 bytes) // // 1 xrefs: // > @ 0xa7760 // // 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 cocos2d::ccDrawCubicBezier( const cocos2d::CCPoint *a1, const cocos2d::CCPoint *a2, const cocos2d::CCPoint *a3, const cocos2d::CCPoint *a4, unsigned int a5) { float *v10; // x24 float v11; // s8 float *v12; // x28 float v13; // s10 float v14; // s9 float v15; // s13 float v16; // s0 float y; // s3 cocos2d::CCGLProgram *v18; // x0 float *v19; // x1 if ( !byte_12451A0 ) sub_AD7B20(); v10 = (float *)operator new[](8LL * (a5 + 1)); if ( a5 ) { v11 = 0.0; v12 = v10 + 1; do { v13 = (float)((float)((float)(1.0 - v11) * (float)(1.0 - v11)) * 3.0) * v11; v14 = (float)((float)((float)(1.0 - v11) * 3.0) * v11) * v11; v15 = (float)(v11 * v11) * v11; *(v12 - 1) = (float)((float)((float)(v13 * a2->x) + (float)(powf(1.0 - v11, 3.0) * a1->x)) + (float)(v14 * a3->x)) + (float)(v15 * a4->x); v16 = powf(1.0 - v11, 3.0); y = a4->y; v11 = v11 + (float)(1.0 / (float)a5); *v12 = (float)((float)((float)(v13 * a2->y) + (float)(v16 * a1->y)) + (float)(v14 * a3->y)) + (float)(v15 * y); v12 += 2; } while ( v12 != &v10[2 * a5 + 1] ); } else { y = a4->y; } v18 = (cocos2d::CCGLProgram *)qword_1245198; v19 = &v10[2 * a5]; *v19 = a4->x; v19[1] = y; cocos2d::CCGLProgram::use(v18); cocos2d::CCGLProgram::setUniformsForBuiltins((cocos2d::CCGLProgram *)qword_1245198); cocos2d::CCGLProgram::setUniformLocationWith4fv( (cocos2d::CCGLProgram *)qword_1245198, dword_1230CC8, (float *)&dword_1230CD0, 1u); cocos2d::ccGLEnableVertexAttribs((unsigned int)&dword_0 + 1); glVertexAttribPointer(); glDrawArrays(); operator delete[](v10); ++g_uNumberOfDraws; }
GD Web Decomp Icon

GD Web Decomp

Raw Source