{"type": "func", "start": 6442518432, "end": 6442518579, "name": "cocos2d::CCString::initWithFormatAndValist", "pseudocode": "// \n// cocos2d::CCString::initWithFormatAndValist from 0x1800107a0 to 0x180010833 (147 bytes)\n// \n// 5 xrefs:\n// > cocos2d::CCString::createWithFormat @ 0x1800106db\n// > cocos2d::CCString::initWithFormat @ 0x180010796\n// > <???> @ 0x18014cf68\n// > <???> @ 0x1801b81e8\n// > <???> @ 0x1801b81f4\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:22 +0000\n// \n\nbool __fastcall cocos2d::CCString::initWithFormatAndValist(void **this, const char *a2, va_list a3)\n{\n  char *v6; // rax\n  char *v7; // rbx\n  _QWORD *v8; // rax\n  size_t v9; // rax\n\n  v6 = (char *)malloc(0x19000u);\n  v7 = v6;\n  if ( v6 )\n  {\n    v8 = sub_1800095E0();\n    _stdio_common_vsprintf(*v8 | 2LL, v7, 0x19000u, a2, nullptr, a3);\n    v9 = strlen(v7);\n    sub_1800101E0(this + 7, v7, v9);\n    free(v7);\n    LOBYTE(v6) = 1;\n  }\n  return (char)v6;\n}", "assembly": "; \n; cocos2d::CCString::initWithFormatAndValist from 0x1800107a0 to 0x180010833 (147 bytes)\n; \n; 5 xrefs:\n; > cocos2d::CCString::createWithFormat @ 0x1800106db\n; > cocos2d::CCString::initWithFormat @ 0x180010796\n; > <???> @ 0x18014cf68\n; > <???> @ 0x1801b81e8\n; > <???> @ 0x1801b81f4\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:22 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x1800107a0\nmov     [rsp+arg_8], rbp                                               ; +0x5, 0x1800107a5\nmov     [rsp+arg_10], rsi                                              ; +0xa, 0x1800107aa\npush    rdi                                                            ; +0xf, 0x1800107af\nsub     rsp, 30h                                                       ; +0x10, 0x1800107b0\nmov     rbp, rcx                                                       ; +0x14, 0x1800107b4\nmov     rdi, r8                                                        ; +0x17, 0x1800107b7\nmov     ecx, 19000h; Size                                              ; +0x1a, 0x1800107ba\nmov     rsi, rdx                                                       ; +0x1f, 0x1800107bf\ncall    cs:__imp_malloc                                                ; +0x22, 0x1800107c2\nmov     rbx, rax                                                       ; +0x28, 0x1800107c8\ntest    rax, rax                                                       ; +0x2b, 0x1800107cb\njz      short loc_18001081E                                            ; +0x2e, 0x1800107ce\ncall    sub_1800095E0                                                  ; +0x30, 0x1800107d0\nmov     [rsp+38h+ArgList], rdi; ArgList                                ; +0x35, 0x1800107d5\nmov     r9, rsi; Format                                                ; +0x3a, 0x1800107da\nmov     r8d, 19000h; BufferCount                                       ; +0x3d, 0x1800107dd\nmov     [rsp+38h+Locale], 0; Locale                                    ; +0x43, 0x1800107e3\nmov     rdx, rbx; Buffer                                               ; +0x4c, 0x1800107ec\nmov     rcx, [rax]                                                     ; +0x4f, 0x1800107ef\nor      rcx, 2; Options                                                ; +0x52, 0x1800107f2\ncall    cs:__stdio_common_vsprintf                                     ; +0x56, 0x1800107f6\nmov     rcx, rbx; Str                                                  ; +0x5c, 0x1800107fc\ncall    strlen                                                         ; +0x5f, 0x1800107ff\nlea     rcx, [rbp+38h]; void *                                         ; +0x64, 0x180010804\nmov     r8, rax; Size                                                  ; +0x68, 0x180010808\nmov     rdx, rbx; Src                                                  ; +0x6b, 0x18001080b\ncall    sub_1800101E0                                                  ; +0x6e, 0x18001080e\nmov     rcx, rbx; Block                                                ; +0x73, 0x180010813\ncall    cs:__imp_free                                                  ; +0x76, 0x180010816\nmov     al, 1                                                          ; +0x7c, 0x18001081c\nmov     rbx, [rsp+38h+arg_0]                                           ; +0x7e, 0x18001081e\nmov     rbp, [rsp+38h+arg_8]                                           ; +0x83, 0x180010823\nmov     rsi, [rsp+38h+arg_10]                                          ; +0x88, 0x180010828\nadd     rsp, 30h                                                       ; +0x8d, 0x18001082d\npop     rdi                                                            ; +0x91, 0x180010831\nretn                                                                   ; +0x92, 0x180010832", "xrefs": ["cocos2d::CCString::createWithFormat @ 0x1800106db", "cocos2d::CCString::initWithFormat @ 0x180010796", "<???> @ 0x18014cf68", "<???> @ 0x1801b81e8", "<???> @ 0x1801b81f4"], "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"}