{"type": "func", "start": 6443248800, "end": 6443249152, "name": "cocos2d::CCDirector::setDefaultValues", "pseudocode": "// \n// cocos2d::CCDirector::setDefaultValues from 0x1800c2ca0 to 0x1800c2e00 (352 bytes)\n// \n// 4 xrefs:\n// > cocos2d::CCConfiguration::loadConfigFile @ 0x1800c129b\n// > cocos2d::CCDirector::init @ 0x1800c1fbd\n// > <???> @ 0x18014cf68\n// > <???> @ 0x1801c35b8\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:22:26 +0000\n// \n\nvoid __fastcall cocos2d::CCDirector::setDefaultValues(cocos2d::CCDirector *this)\n{\n  cocos2d::CCConfiguration *v2; // rsi\n  __m128d v3; // xmm1\n  const char *CString; // rdi\n  const char *v5; // rbx\n  int v6; // ecx\n  char Bool; // al\n\n  v2 = cocos2d::CCConfiguration::sharedConfiguration();\n  v3 = (__m128d)0x3FF0000000000000uLL;\n  v3.m128d_f64[0] = 1.0 / cocos2d::CCConfiguration::getNumber(v2, \"cocos2d.x.fps\", 60.0);\n  *(__m128d *)((char *)this + 200) = _mm_unpacklo_pd(v3, v3);\n  *((_BYTE *)this + 217) = cocos2d::CCConfiguration::getBool(v2, \"cocos2d.x.display_fps\", 0);\n  CString = cocos2d::CCConfiguration::getCString(v2, \"cocos2d.x.gl.projection\", \"3d\");\n  if ( !strcmp(CString, \"3d\") )\n  {\n    *((_DWORD *)this + 79) = 1;\n  }\n  else if ( !strcmp(CString, \"2d\") )\n  {\n    *((_DWORD *)this + 79) = 0;\n  }\n  else if ( !strcmp(CString, \"custom\") )\n  {\n    *((_DWORD *)this + 79) = 2;\n  }\n  v5 = cocos2d::CCConfiguration::getCString(v2, \"cocos2d.x.texture.pixel_format_for_png\", \"rgba8888\");\n  if ( !strcmp(v5, \"rgba8888\") )\n  {\n    v6 = 0;\nLABEL_13:\n    cocos2d::CCTexture2D::setDefaultAlphaPixelFormat(v6);\n    goto LABEL_14;\n  }\n  if ( !strcmp(v5, \"rgba4444\") )\n  {\n    v6 = 6;\n    goto LABEL_13;\n  }\n  if ( !strcmp(v5, \"rgba5551\") )\n  {\n    v6 = 7;\n    goto LABEL_13;\n  }\nLABEL_14:\n  Bool = cocos2d::CCConfiguration::getBool(v2, \"cocos2d.x.texture.pvrv2_has_alpha_premultiplied\", 0);\n  cocos2d::CCTexture2D::PVRImagesHavePremultipliedAlpha(Bool);\n}", "assembly": "; \n; cocos2d::CCDirector::setDefaultValues from 0x1800c2ca0 to 0x1800c2e00 (352 bytes)\n; \n; 4 xrefs:\n; > cocos2d::CCConfiguration::loadConfigFile @ 0x1800c129b\n; > cocos2d::CCDirector::init @ 0x1800c1fbd\n; > <???> @ 0x18014cf68\n; > <???> @ 0x1801c35b8\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:22:26 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x1800c2ca0\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x1800c2ca5\npush    rdi                                                            ; +0xa, 0x1800c2caa\nsub     rsp, 20h                                                       ; +0xb, 0x1800c2cab\nmov     rbx, rcx                                                       ; +0xf, 0x1800c2caf\ncall    ?sharedConfiguration@CCConfiguration@cocos2d@@SAPEAV12@XZ; cocos2d::CCConfiguration::sharedConfiguration(void) ; +0x12, 0x1800c2cb2\nmovsd   xmm2, cs:dbl_180106ED8; double                                 ; +0x17, 0x1800c2cb7\nlea     rdx, aCocos2dXFps; \"cocos2d.x.fps\"                             ; +0x1f, 0x1800c2cbf\nmov     rcx, rax; this                                                 ; +0x26, 0x1800c2cc6\nmov     rsi, rax                                                       ; +0x29, 0x1800c2cc9\ncall    ?getNumber@CCConfiguration@cocos2d@@QEBANPEBDN@Z; cocos2d::CCConfiguration::getNumber(char const *,double) ; +0x2c, 0x1800c2ccc\nmovsd   xmm1, cs:depth                                                 ; +0x31, 0x1800c2cd1\nlea     rdx, aCocos2dXDispla; \"cocos2d.x.display_fps\"                  ; +0x39, 0x1800c2cd9\ndivsd   xmm1, xmm0                                                     ; +0x40, 0x1800c2ce0\nxor     r8d, r8d; bool                                                 ; +0x44, 0x1800c2ce4\nmov     rcx, rsi; this                                                 ; +0x47, 0x1800c2ce7\nunpcklpd xmm1, xmm1                                                    ; +0x4a, 0x1800c2cea\nmovups  xmmword ptr [rbx+0C8h], xmm1                                   ; +0x4e, 0x1800c2cee\ncall    ?getBool@CCConfiguration@cocos2d@@QEBA_NPEBD_N@Z; cocos2d::CCConfiguration::getBool(char const *,bool) ; +0x55, 0x1800c2cf5\nlea     r8, a3d; \"3d\"                                                  ; +0x5a, 0x1800c2cfa\nmov     [rbx+0D9h], al                                                 ; +0x61, 0x1800c2d01\nlea     rdx, aCocos2dXGlProj; \"cocos2d.x.gl.projection\"                ; +0x67, 0x1800c2d07\nmov     rcx, rsi; this                                                 ; +0x6e, 0x1800c2d0e\ncall    ?getCString@CCConfiguration@cocos2d@@QEBAPEBDPEBD0@Z; cocos2d::CCConfiguration::getCString(char const *,char const *) ; +0x71, 0x1800c2d11\nlea     rdx, a3d; \"3d\"                                                 ; +0x76, 0x1800c2d16\nmov     rcx, rax; Str1                                                 ; +0x7d, 0x1800c2d1d\nmov     rdi, rax                                                       ; +0x80, 0x1800c2d20\ncall    strcmp                                                         ; +0x83, 0x1800c2d23\ntest    eax, eax                                                       ; +0x88, 0x1800c2d28\njnz     short loc_1800C2D38                                            ; +0x8a, 0x1800c2d2a\nmov     dword ptr [rbx+13Ch], 1                                        ; +0x8c, 0x1800c2d2c\njmp     short loc_1800C2D70                                            ; +0x96, 0x1800c2d36\nlea     rdx, a2d; \"2d\"                                                 ; +0x98, 0x1800c2d38\nmov     rcx, rdi; Str1                                                 ; +0x9f, 0x1800c2d3f\ncall    strcmp                                                         ; +0xa2, 0x1800c2d42\ntest    eax, eax                                                       ; +0xa7, 0x1800c2d47\njnz     short loc_1800C2D53                                            ; +0xa9, 0x1800c2d49\nmov     [rbx+13Ch], eax                                                ; +0xab, 0x1800c2d4b\njmp     short loc_1800C2D70                                            ; +0xb1, 0x1800c2d51\nlea     rdx, aCustom; \"custom\"                                         ; +0xb3, 0x1800c2d53\nmov     rcx, rdi; Str1                                                 ; +0xba, 0x1800c2d5a\ncall    strcmp                                                         ; +0xbd, 0x1800c2d5d\ntest    eax, eax                                                       ; +0xc2, 0x1800c2d62\njnz     short loc_1800C2D70                                            ; +0xc4, 0x1800c2d64\nmov     dword ptr [rbx+13Ch], 2                                        ; +0xc6, 0x1800c2d66\nlea     r8, aRgba8888_0; \"rgba8888\"                                    ; +0xd0, 0x1800c2d70\nmov     rcx, rsi; this                                                 ; +0xd7, 0x1800c2d77\nlea     rdx, aCocos2dXTextur; \"cocos2d.x.texture.pixel_format_for_png\" ; +0xda, 0x1800c2d7a\ncall    ?getCString@CCConfiguration@cocos2d@@QEBAPEBDPEBD0@Z; cocos2d::CCConfiguration::getCString(char const *,char const *) ; +0xe1, 0x1800c2d81\nlea     rdx, aRgba8888_0; \"rgba8888\"                                   ; +0xe6, 0x1800c2d86\nmov     rcx, rax; Str1                                                 ; +0xed, 0x1800c2d8d\nmov     rbx, rax                                                       ; +0xf0, 0x1800c2d90\ncall    strcmp                                                         ; +0xf3, 0x1800c2d93\ntest    eax, eax                                                       ; +0xf8, 0x1800c2d98\njnz     short loc_1800C2DA0                                            ; +0xfa, 0x1800c2d9a\nxor     ecx, ecx                                                       ; +0xfc, 0x1800c2d9c\njmp     short loc_1800C2DD2                                            ; +0xfe, 0x1800c2d9e\nlea     rdx, aRgba4444_0; \"rgba4444\"                                   ; +0x100, 0x1800c2da0\nmov     rcx, rbx; Str1                                                 ; +0x107, 0x1800c2da7\ncall    strcmp                                                         ; +0x10a, 0x1800c2daa\ntest    eax, eax                                                       ; +0x10f, 0x1800c2daf\njnz     short loc_1800C2DBA                                            ; +0x111, 0x1800c2db1\nmov     ecx, 6                                                         ; +0x113, 0x1800c2db3\njmp     short loc_1800C2DD2                                            ; +0x118, 0x1800c2db8\nlea     rdx, aRgba5551; \"rgba5551\"                                     ; +0x11a, 0x1800c2dba\nmov     rcx, rbx; Str1                                                 ; +0x121, 0x1800c2dc1\ncall    strcmp                                                         ; +0x124, 0x1800c2dc4\ntest    eax, eax                                                       ; +0x129, 0x1800c2dc9\njnz     short loc_1800C2DD7                                            ; +0x12b, 0x1800c2dcb\nmov     ecx, 7                                                         ; +0x12d, 0x1800c2dcd\ncall    ?setDefaultAlphaPixelFormat@CCTexture2D@cocos2d@@SAXW4CCTexture2DPixelFormat@2@@Z; cocos2d::CCTexture2D::setDefaultAlphaPixelFormat(cocos2d::CCTexture2DPixelFormat) ; +0x132, 0x1800c2dd2\nxor     r8d, r8d; bool                                                 ; +0x137, 0x1800c2dd7\nlea     rdx, aCocos2dXTextur_0; \"cocos2d.x.texture.pvrv2_has_alpha_premu\"... ; +0x13a, 0x1800c2dda\nmov     rcx, rsi; this                                                 ; +0x141, 0x1800c2de1\ncall    ?getBool@CCConfiguration@cocos2d@@QEBA_NPEBD_N@Z; cocos2d::CCConfiguration::getBool(char const *,bool) ; +0x144, 0x1800c2de4\nmovzx   ecx, al; bool                                                  ; +0x149, 0x1800c2de9\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x14c, 0x1800c2dec\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x151, 0x1800c2df1\nadd     rsp, 20h                                                       ; +0x156, 0x1800c2df6\npop     rdi                                                            ; +0x15a, 0x1800c2dfa\njmp     ?PVRImagesHavePremultipliedAlpha@CCTexture2D@cocos2d@@SAX_N@Z; cocos2d::CCTexture2D::PVRImagesHavePremultipliedAlpha(bool) ; +0x15b, 0x1800c2dfb", "xrefs": ["cocos2d::CCConfiguration::loadConfigFile @ 0x1800c129b", "cocos2d::CCDirector::init @ 0x1800c1fbd", "<???> @ 0x18014cf68", "<???> @ 0x1801c35b8"], "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"}