{"type": "func", "start": 6442784672, "end": 6442784832, "name": "cocos2d::CCLayerGradient::create", "pseudocode": "// \n// cocos2d::CCLayerGradient::create from 0x1800517a0 to 0x180051840 (160 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0x18014cf68\n// > <???> @ 0x1801bc0e8\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:21:45 +0000\n// \n\n// Hidden C++ exception states: #wind=1\nstruct cocos2d::CCLayerGradient *__fastcall cocos2d::CCLayerGradient::create(\n        const struct cocos2d::_ccColor4B *a1,\n        const struct cocos2d::_ccColor4B *a2,\n        const struct cocos2d::CCPoint *a3)\n{\n  cocos2d::CCLayerGradient *v6; // rax\n  cocos2d::CCLayerGradient *v7; // rbx\n  cocos2d::CCObject *v8; // rbx\n\n  v6 = (cocos2d::CCLayerGradient *)sub_1800E4AC0(0x238u);\n  v7 = v6;\n  if ( v6 )\n  {\n    memset(v6, 0, 0x238u);\n    v8 = cocos2d::CCLayerGradient::CCLayerGradient(v7);\n  }\n  else\n  {\n    v8 = nullptr;\n  }\n  if ( v8 )\n  {\n    if ( (*(unsigned __int8 (__fastcall **)(cocos2d::CCObject *, const struct cocos2d::_ccColor4B *, const struct cocos2d::_ccColor4B *, const struct cocos2d::CCPoint *))(*(_QWORD *)v8 + 1056LL))(\n           v8,\n           a1,\n           a2,\n           a3) )\n    {\n      cocos2d::CCObject::autorelease(v8);\n      return v8;\n    }\n    (*(void (__fastcall **)(cocos2d::CCObject *, __int64))(*(_QWORD *)v8 + 8LL))(v8, 1);\n  }\n  return nullptr;\n}", "assembly": "; \n; cocos2d::CCLayerGradient::create from 0x1800517a0 to 0x180051840 (160 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0x18014cf68\n; > <???> @ 0x1801bc0e8\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:21:45 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x1800517a0\nmov     [rsp+arg_8], rbp                                               ; +0x5, 0x1800517a5\nmov     [rsp+arg_10], rsi                                              ; +0xa, 0x1800517aa\npush    rdi                                                            ; +0xf, 0x1800517af\nsub     rsp, 20h                                                       ; +0x10, 0x1800517b0\nmov     rdi, r8                                                        ; +0x14, 0x1800517b4\nmov     rsi, rdx                                                       ; +0x17, 0x1800517b7\nmov     rbp, rcx                                                       ; +0x1a, 0x1800517ba\nmov     ecx, 238h; Size                                                ; +0x1d, 0x1800517bd\ncall    sub_1800E4AC0                                                  ; +0x22, 0x1800517c2\nmov     rbx, rax                                                       ; +0x27, 0x1800517c7\nmov     [rsp+28h+arg_18], rax                                          ; +0x2a, 0x1800517ca\ntest    rax, rax                                                       ; +0x2f, 0x1800517cf\njz      short loc_1800517F1                                            ; +0x32, 0x1800517d2\nxor     edx, edx; Val                                                  ; +0x34, 0x1800517d4\nmov     r8d, 238h; Size                                                ; +0x36, 0x1800517d6\nmov     rcx, rax; void *                                               ; +0x3c, 0x1800517dc\ncall    memset                                                         ; +0x3f, 0x1800517df\nmov     rcx, rbx; this                                                 ; +0x44, 0x1800517e4\ncall    ??0CCLayerGradient@cocos2d@@QEAA@XZ; cocos2d::CCLayerGradient::CCLayerGradient(void) ; +0x47, 0x1800517e7\nmov     rbx, rax                                                       ; +0x4c, 0x1800517ec\njmp     short loc_1800517F3                                            ; +0x4f, 0x1800517ef\nxor     ebx, ebx                                                       ; +0x51, 0x1800517f1\ntest    rbx, rbx                                                       ; +0x53, 0x1800517f3\njz      short loc_180051829                                            ; +0x56, 0x1800517f6\nmov     rax, [rbx]                                                     ; +0x58, 0x1800517f8\nmov     r9, rdi                                                        ; +0x5b, 0x1800517fb\nmov     r8, rsi                                                        ; +0x5e, 0x1800517fe\nmov     rdx, rbp                                                       ; +0x61, 0x180051801\nmov     rcx, rbx                                                       ; +0x64, 0x180051804\ncall    qword ptr [rax+420h]                                           ; +0x67, 0x180051807\nmov     rcx, rbx; this                                                 ; +0x6d, 0x18005180d\ntest    al, al                                                         ; +0x70, 0x180051810\njz      short loc_18005181E                                            ; +0x72, 0x180051812\ncall    ?autorelease@CCObject@cocos2d@@QEAAPEAV12@XZ; cocos2d::CCObject::autorelease(void) ; +0x74, 0x180051814\nmov     rax, rbx                                                       ; +0x79, 0x180051819\njmp     short loc_18005182B                                            ; +0x7c, 0x18005181c\nmov     rax, [rbx]                                                     ; +0x7e, 0x18005181e\nmov     edx, 1                                                         ; +0x81, 0x180051821\ncall    qword ptr [rax+8]                                              ; +0x86, 0x180051826\nxor     eax, eax                                                       ; +0x89, 0x180051829\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x8b, 0x18005182b\nmov     rbp, [rsp+28h+arg_8]                                           ; +0x90, 0x180051830\nmov     rsi, [rsp+28h+arg_10]                                          ; +0x95, 0x180051835\nadd     rsp, 20h                                                       ; +0x9a, 0x18005183a\npop     rdi                                                            ; +0x9e, 0x18005183e\nretn                                                                   ; +0x9f, 0x18005183f", "xrefs": ["<???> @ 0x18014cf68", "<???> @ 0x1801bc0e8"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}