{"type": "func", "start": 6442532752, "end": 6442533563, "name": "cocos2d::CCDrawNode::drawPreciseCubicBezier", "pseudocode": "// \n// cocos2d::CCDrawNode::drawPreciseCubicBezier from 0x180013f90 to 0x1800142bb (811 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0x1801438a8\n// > <???> @ 0x1801ae428\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\nvoid __fastcall cocos2d::CCDrawNode::drawPreciseCubicBezier(\n        cocos2d::CCDrawNode *this,\n        struct cocos2d::CCPoint *a2,\n        struct cocos2d::CCPoint *a3,\n        const struct cocos2d::CCPoint *a4,\n        struct cocos2d::CCPoint *a5,\n        unsigned int a6,\n        const struct cocos2d::_ccColor4F *a7,\n        float a8)\n{\n  float Distance; // xmm9_4\n  float v13; // xmm0_4\n  struct cocos2d::CCPoint *v14; // rsi\n  float v15; // xmm7_4\n  float v16; // xmm0_4\n  float v17; // xmm9_4\n  float v18; // xmm11_4\n  float v19; // xmm7_4\n  float v20; // xmm12_4\n  float v21; // xmm15_4\n  float v22; // xmm15_4\n  float v23; // xmm9_4\n  float v24; // xmm11_4\n  float v25; // xmm6_4\n  float v26; // xmm8_4\n  float v27; // xmm6_4\n  float v28; // xmm7_4\n  const struct cocos2d::CCPoint *v29; // rbx\n  const struct cocos2d::CCPoint *v30; // rax\n  float v31; // [rsp+40h] [rbp-C8h]\n  float v32; // [rsp+118h] [rbp+10h]\n  float v33; // [rsp+120h] [rbp+18h]\n  float X; // [rsp+128h] [rbp+20h] BYREF\n\n  Distance = cocos2d::CCPoint::getDistance(a2, a3);\n  v13 = cocos2d::CCPoint::getDistance(a3, a4);\n  v14 = a5;\n  v15 = v13 + Distance;\n  v16 = cocos2d::CCPoint::getDistance(a5, a4) + (float)(v13 + Distance);\n  v17 = Distance / v16;\n  *(float *)&a5 = v15 / v16;\n  X = 1.0 - (float)(v15 / v16);\n  v18 = (float)(1.0 - *(float *)&a5) * *(float *)&a5;\n  v32 = (float)((float)((float)(1.0 - v17) * v17) * v17) * 3.0;\n  v19 = (float)(v18 * X) * 3.0;\n  v33 = (float)((float)((float)(1.0 - v17) * v17) * (float)(1.0 - v17)) * 3.0;\n  v20 = a3->x - (float)(powf(1.0 - v17, 3.0) * a2->x);\n  v31 = v20 - (float)(powf(v17, 3.0) * v14->x);\n  v21 = a3->y - (float)(powf(1.0 - v17, 3.0) * a2->y);\n  v22 = v21 - (float)(powf(v17, 3.0) * v14->y);\n  v23 = v32 - (float)((float)((float)((float)(v18 * *(float *)&a5) * 3.0) * v33) / v19);\n  v24 = X;\n  v25 = a4->x - (float)(powf(X, 3.0) * a2->x);\n  v26 = (float)(v31 - (float)((float)(v25 - (float)(powf(*(float *)&a5, 3.0) * v14->x)) * (float)(v33 / v19))) / v23;\n  v27 = a4->y - (float)(powf(v24, 3.0) * a2->y);\n  v28 = (float)(v22 - (float)((float)(v27 - (float)(powf(*(float *)&a5, 3.0) * v14->y)) * (float)(v33 / v19))) / v23;\n  v29 = (const struct cocos2d::CCPoint *)kmVec2Fill((float *)&a5, v26, v28);\n  v30 = (const struct cocos2d::CCPoint *)kmVec2Fill(\n                                           &X,\n                                           (float)(v31 - (float)(v26 * v32)) / v33,\n                                           (float)(v22 - (float)(v28 * v32)) / v33);\n  cocos2d::CCDrawNode::drawCubicBezier(this, a2, v30, v29, v14, a6, a7, a8);\n}", "assembly": "; \n; cocos2d::CCDrawNode::drawPreciseCubicBezier from 0x180013f90 to 0x1800142bb (811 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0x1801438a8\n; > <???> @ 0x1801ae428\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\nmov     rax, rsp                                                       ; +0x0, 0x180013f90\npush    rbx                                                            ; +0x3, 0x180013f93\npush    rbp                                                            ; +0x4, 0x180013f94\npush    rsi                                                            ; +0x5, 0x180013f95\npush    rdi                                                            ; +0x6, 0x180013f96\npush    r14                                                            ; +0x7, 0x180013f97\nsub     rsp, 0E0h                                                      ; +0x9, 0x180013f99\nmovaps  xmmword ptr [rax-38h], xmm6                                    ; +0x10, 0x180013fa0\nmov     rbp, rdx                                                       ; +0x14, 0x180013fa4\nmovaps  xmmword ptr [rax-48h], xmm7                                    ; +0x17, 0x180013fa7\nmov     r14, rcx                                                       ; +0x1b, 0x180013fab\nmovaps  xmmword ptr [rax-58h], xmm8                                    ; +0x1e, 0x180013fae\nmov     rdx, r8; struct cocos2d::CCPoint *                             ; +0x23, 0x180013fb3\nmovaps  xmmword ptr [rax-68h], xmm9                                    ; +0x26, 0x180013fb6\nmov     rcx, rbp; this                                                 ; +0x2b, 0x180013fbb\nmovaps  xmmword ptr [rax-78h], xmm10                                   ; +0x2e, 0x180013fbe\nmov     rdi, r9                                                        ; +0x33, 0x180013fc3\nmovaps  xmmword ptr [rax-88h], xmm11                                   ; +0x36, 0x180013fc6\nmov     rbx, r8                                                        ; +0x3e, 0x180013fce\nmovaps  [rsp+108h+var_98], xmm12                                       ; +0x41, 0x180013fd1\nmovaps  [rsp+108h+var_A8], xmm13                                       ; +0x47, 0x180013fd7\nmovaps  [rsp+108h+var_B8], xmm15                                       ; +0x4d, 0x180013fdd\ncall    ?getDistance@CCPoint@cocos2d@@QEBAMAEBV12@@Z; cocos2d::CCPoint::getDistance(cocos2d::CCPoint const &) ; +0x53, 0x180013fe3\nmov     rdx, rdi; struct cocos2d::CCPoint *                            ; +0x58, 0x180013fe8\nmov     rcx, rbx; this                                                 ; +0x5b, 0x180013feb\nmovaps  xmm9, xmm0                                                     ; +0x5e, 0x180013fee\ncall    ?getDistance@CCPoint@cocos2d@@QEBAMAEBV12@@Z; cocos2d::CCPoint::getDistance(cocos2d::CCPoint const &) ; +0x62, 0x180013ff2\nmov     rsi, [rsp+108h+arg_20]                                         ; +0x67, 0x180013ff7\nmovaps  xmm7, xmm0                                                     ; +0x6f, 0x180013fff\nmov     rcx, rsi; this                                                 ; +0x72, 0x180014002\naddss   xmm7, xmm9                                                     ; +0x75, 0x180014005\nmov     rdx, rdi; struct cocos2d::CCPoint *                            ; +0x7a, 0x18001400a\ncall    ?getDistance@CCPoint@cocos2d@@QEBAMAEBV12@@Z; cocos2d::CCPoint::getDistance(cocos2d::CCPoint const &) ; +0x7d, 0x18001400d\nmovss   xmm10, cs:flt_1800E6700                                        ; +0x82, 0x180014012\naddss   xmm0, xmm7                                                     ; +0x8b, 0x18001401b\ndivss   xmm7, xmm0                                                     ; +0x8f, 0x18001401f\ndivss   xmm9, xmm0                                                     ; +0x93, 0x180014023\nmovss   xmm0, cs:flt_1800E61A8                                         ; +0x98, 0x180014028\nmovaps  xmm6, xmm0                                                     ; +0xa0, 0x180014030\nmovss   dword ptr [rsp+108h+arg_20], xmm7                              ; +0xa3, 0x180014033\nsubss   xmm0, xmm7                                                     ; +0xac, 0x18001403c\nsubss   xmm6, xmm9                                                     ; +0xb0, 0x180014040\nmovaps  xmm11, xmm0                                                    ; +0xb5, 0x180014045\nmovss   [rsp+108h+X], xmm0                                             ; +0xb9, 0x180014049\nmovaps  xmm1, xmm6                                                     ; +0xc2, 0x180014052\nmulss   xmm11, xmm7                                                    ; +0xc5, 0x180014055\nmulss   xmm1, xmm9                                                     ; +0xca, 0x18001405a\nmovaps  xmm7, xmm11                                                    ; +0xcf, 0x18001405f\nmulss   xmm7, xmm0                                                     ; +0xd3, 0x180014063\nmovaps  xmm0, xmm6; X                                                  ; +0xd7, 0x180014067\nmovaps  xmm2, xmm1                                                     ; +0xda, 0x18001406a\nmulss   xmm1, xmm9                                                     ; +0xdd, 0x18001406d\nmulss   xmm2, xmm6                                                     ; +0xe2, 0x180014072\nmulss   xmm1, xmm10                                                    ; +0xe6, 0x180014076\nmulss   xmm2, xmm10                                                    ; +0xeb, 0x18001407b\nmovss   [rsp+108h+arg_8], xmm1                                         ; +0xf0, 0x180014080\nmovaps  xmm1, xmm10; Y                                                 ; +0xf9, 0x180014089\nmulss   xmm7, xmm10                                                    ; +0xfd, 0x18001408d\nmovss   [rsp+108h+arg_10], xmm2                                        ; +0x102, 0x180014092\ncall    powf                                                           ; +0x10b, 0x18001409b\nmulss   xmm0, dword ptr [rbp+0]                                        ; +0x110, 0x1800140a0\nmovaps  xmm1, xmm10; Y                                                 ; +0x115, 0x1800140a5\nmovss   xmm12, dword ptr [rbx]                                         ; +0x119, 0x1800140a9\nsubss   xmm12, xmm0                                                    ; +0x11e, 0x1800140ae\nmovaps  xmm0, xmm9; X                                                  ; +0x123, 0x1800140b3\ncall    powf                                                           ; +0x127, 0x1800140b7\nmulss   xmm0, dword ptr [rsi]                                          ; +0x12c, 0x1800140bc\nmovaps  xmm1, xmm10; Y                                                 ; +0x130, 0x1800140c0\nsubss   xmm12, xmm0                                                    ; +0x134, 0x1800140c4\nmovaps  xmm0, xmm6; X                                                  ; +0x139, 0x1800140c9\nmovss   [rsp+108h+var_C8], xmm12                                       ; +0x13c, 0x1800140cc\ncall    powf                                                           ; +0x143, 0x1800140d3\nmulss   xmm0, dword ptr [rbp+4]                                        ; +0x148, 0x1800140d8\nmovaps  xmm1, xmm10; Y                                                 ; +0x14d, 0x1800140dd\nmovss   xmm15, dword ptr [rbx+4]                                       ; +0x151, 0x1800140e1\nsubss   xmm15, xmm0                                                    ; +0x157, 0x1800140e7\nmovaps  xmm0, xmm9; X                                                  ; +0x15c, 0x1800140ec\ncall    powf                                                           ; +0x160, 0x1800140f0\nmulss   xmm11, dword ptr [rsp+108h+arg_20]                             ; +0x165, 0x1800140f5\nmulss   xmm0, dword ptr [rsi+4]                                        ; +0x16f, 0x1800140ff\nmulss   xmm11, cs:flt_1800E6700                                        ; +0x174, 0x180014104\nmovss   xmm9, [rsp+108h+arg_8]                                         ; +0x17d, 0x18001410d\nsubss   xmm15, xmm0                                                    ; +0x187, 0x180014117\nmovss   xmm0, [rsp+108h+arg_10]                                        ; +0x18c, 0x18001411c\nmulss   xmm11, xmm0                                                    ; +0x195, 0x180014125\nmovaps  xmm10, xmm0                                                    ; +0x19a, 0x18001412a\ndivss   xmm10, xmm7                                                    ; +0x19e, 0x18001412e\ndivss   xmm11, xmm7                                                    ; +0x1a3, 0x180014133\nmovss   xmm7, cs:flt_1800E6700                                         ; +0x1a8, 0x180014138\nsubss   xmm9, xmm11                                                    ; +0x1b0, 0x180014140\nmovss   xmm11, [rsp+108h+X]                                            ; +0x1b5, 0x180014145\nmovaps  xmm1, xmm7; Y                                                  ; +0x1bf, 0x18001414f\nmovaps  xmm0, xmm11; X                                                 ; +0x1c2, 0x180014152\ncall    powf                                                           ; +0x1c6, 0x180014156\nmulss   xmm0, dword ptr [rbp+0]                                        ; +0x1cb, 0x18001415b\nmovaps  xmm1, xmm7; Y                                                  ; +0x1d0, 0x180014160\nmovss   xmm6, dword ptr [rdi]                                          ; +0x1d3, 0x180014163\nsubss   xmm6, xmm0                                                     ; +0x1d7, 0x180014167\nmovss   xmm0, dword ptr [rsp+108h+arg_20]; X                           ; +0x1db, 0x18001416b\ncall    powf                                                           ; +0x1e4, 0x180014174\nmulss   xmm0, dword ptr [rsi]                                          ; +0x1e9, 0x180014179\nmovaps  xmm1, xmm7; Y                                                  ; +0x1ed, 0x18001417d\nmovss   xmm13, [rsp+108h+var_C8]                                       ; +0x1f0, 0x180014180\nmovaps  xmm8, xmm13                                                    ; +0x1f7, 0x180014187\nsubss   xmm6, xmm0                                                     ; +0x1fb, 0x18001418b\nmovaps  xmm0, xmm11; X                                                 ; +0x1ff, 0x18001418f\nmulss   xmm6, xmm10                                                    ; +0x203, 0x180014193\nsubss   xmm8, xmm6                                                     ; +0x208, 0x180014198\ndivss   xmm8, xmm9                                                     ; +0x20d, 0x18001419d\ncall    powf                                                           ; +0x212, 0x1800141a2\nmulss   xmm0, dword ptr [rbp+4]                                        ; +0x217, 0x1800141a7\nmovaps  xmm1, xmm7; Y                                                  ; +0x21c, 0x1800141ac\nmovss   xmm6, dword ptr [rdi+4]                                        ; +0x21f, 0x1800141af\nsubss   xmm6, xmm0                                                     ; +0x224, 0x1800141b4\nmovss   xmm0, dword ptr [rsp+108h+arg_20]; X                           ; +0x228, 0x1800141b8\ncall    powf                                                           ; +0x231, 0x1800141c1\nmulss   xmm0, dword ptr [rsi+4]                                        ; +0x236, 0x1800141c6\nlea     rcx, [rsp+108h+arg_20]                                         ; +0x23b, 0x1800141cb\nmovaps  xmm7, xmm15                                                    ; +0x243, 0x1800141d3\nmovaps  xmm1, xmm8                                                     ; +0x247, 0x1800141d7\nsubss   xmm6, xmm0                                                     ; +0x24b, 0x1800141db\nmulss   xmm6, xmm10                                                    ; +0x24f, 0x1800141df\nsubss   xmm7, xmm6                                                     ; +0x254, 0x1800141e4\ndivss   xmm7, xmm9                                                     ; +0x258, 0x1800141e8\nmovaps  xmm2, xmm7                                                     ; +0x25d, 0x1800141ed\ncall    kmVec2Fill                                                     ; +0x260, 0x1800141f0\nmulss   xmm7, [rsp+108h+arg_8]                                         ; +0x265, 0x1800141f5\nlea     rcx, [rsp+108h+X]                                              ; +0x26e, 0x1800141fe\nmov     rbx, rax                                                       ; +0x276, 0x180014206\nmulss   xmm8, [rsp+108h+arg_8]                                         ; +0x279, 0x180014209\nsubss   xmm15, xmm7                                                    ; +0x283, 0x180014213\nsubss   xmm13, xmm8                                                    ; +0x288, 0x180014218\ndivss   xmm15, [rsp+108h+arg_10]                                       ; +0x28d, 0x18001421d\ndivss   xmm13, [rsp+108h+arg_10]                                       ; +0x297, 0x180014227\nmovaps  xmm2, xmm15                                                    ; +0x2a1, 0x180014231\nmovaps  xmm1, xmm13                                                    ; +0x2a5, 0x180014235\ncall    kmVec2Fill                                                     ; +0x2a9, 0x180014239\nmovss   xmm0, [rsp+108h+arg_38]                                        ; +0x2ae, 0x18001423e\nmov     r8, rax; struct cocos2d::CCPoint *                             ; +0x2b7, 0x180014247\nmov     rax, [rsp+108h+arg_30]                                         ; +0x2ba, 0x18001424a\nmov     r9, rbx; struct cocos2d::CCPoint *                             ; +0x2c2, 0x180014252\nmovss   [rsp+108h+var_D0], xmm0; float                                 ; +0x2c5, 0x180014255\nmov     rdx, rbp; struct cocos2d::CCPoint *                            ; +0x2cb, 0x18001425b\nmov     [rsp+108h+var_D8], rax; struct cocos2d::_ccColor4F *           ; +0x2ce, 0x18001425e\nmov     rcx, r14; this                                                 ; +0x2d3, 0x180014263\nmov     eax, [rsp+108h+arg_28]                                         ; +0x2d6, 0x180014266\nmov     [rsp+108h+var_E0], eax; unsigned int                           ; +0x2dd, 0x18001426d\nmov     [rsp+108h+var_E8], rsi; struct cocos2d::CCPoint *              ; +0x2e1, 0x180014271\ncall    ?drawCubicBezier@CCDrawNode@cocos2d@@QEAAXAEBVCCPoint@2@000IAEBU_ccColor4F@2@M@Z; cocos2d::CCDrawNode::drawCubicBezier(cocos2d::CCPoint const &,cocos2d::CCPoint const &,cocos2d::CCPoint const &,cocos2d::CCPoint const &,uint,cocos2d::_ccColor4F const &,float) ; +0x2e6, 0x180014276\nmovaps  xmm15, [rsp+108h+var_B8]                                       ; +0x2eb, 0x18001427b\nlea     r11, [rsp+108h+var_28]                                         ; +0x2f1, 0x180014281\nmovaps  xmm6, xmmword ptr [r11-10h]                                    ; +0x2f9, 0x180014289\nmovaps  xmm7, xmmword ptr [r11-20h]                                    ; +0x2fe, 0x18001428e\nmovaps  xmm8, xmmword ptr [r11-30h]                                    ; +0x303, 0x180014293\nmovaps  xmm9, xmmword ptr [r11-40h]                                    ; +0x308, 0x180014298\nmovaps  xmm10, xmmword ptr [r11-50h]                                   ; +0x30d, 0x18001429d\nmovaps  xmm11, xmmword ptr [r11-60h]                                   ; +0x312, 0x1800142a2\nmovaps  xmm12, xmmword ptr [r11-70h]                                   ; +0x317, 0x1800142a7\nmovaps  xmm13, xmmword ptr [r11-80h]                                   ; +0x31c, 0x1800142ac\nmov     rsp, r11                                                       ; +0x321, 0x1800142b1\npop     r14                                                            ; +0x324, 0x1800142b4\npop     rdi                                                            ; +0x326, 0x1800142b6\npop     rsi                                                            ; +0x327, 0x1800142b7\npop     rbp                                                            ; +0x328, 0x1800142b8\npop     rbx                                                            ; +0x329, 0x1800142b9\nretn                                                                   ; +0x32a, 0x1800142ba", "xrefs": ["<???> @ 0x1801438a8", "<???> @ 0x1801ae428"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}