{"type": "func", "start": 6442943920, "end": 6442944218, "name": "cocos2d::CCEGLView::~CCEGLView", "pseudocode": "// \n// cocos2d::CCEGLView::~CCEGLView from 0x1800785b0 to 0x1800786da (298 bytes)\n// \n// 4 xrefs:\n// > sub_180078700 @ 0x18007875e\n// > sub_180078700 @ 0x18007871c\n// > <???> @ 0x18014cf68\n// > <???> @ 0x1801bea1c\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:59 +0000\n// \n\nvoid __fastcall cocos2d::CCEGLView::~CCEGLView(cocos2d::CCEGLView *this)\n{\n  _Thrd_t v2; // [rsp+20h] [rbp-18h] BYREF\n\n  *(_QWORD *)this = &cocos2d::CCEGLView::`vftable'{for `cocos2d::CCEGLViewProtocol'};\n  *((_QWORD *)this + 15) = &cocos2d::CCEGLView::`vftable'{for `cocos2d::CCObject'};\n  byte_1801B2558 = 0;\n  if ( idThread )\n    PostThreadMessageA(idThread, 0x12u, 0, 0);\n  if ( dword_1801B2568 )\n  {\n    if ( dword_1801B2568 == Thrd_id() )\n    {\nLABEL_12:\n      std::_Throw_Cpp_error(5);\n      JUMPOUT(0x1800786D9LL);\n    }\n    v2 = (_Thrd_t)unk_1801B2560;\n    if ( Thrd_join(&v2, nullptr) )\n    {\n      std::_Throw_Cpp_error(2);\n      __debugbreak();\n    }\n    unk_1801B2560 = 0;\n  }\n  hWnd = nullptr;\n  if ( Mtx_lock((_Mtx_t)&unk_1801B2588) )\n    goto LABEL_12;\n  if ( dword_1801B25D4 == 0x7FFFFFFF )\n  {\n    dword_1801B25D4 = 2147483646;\n    std::_Throw_Cpp_error(6);\n    __debugbreak();\n  }\n  sub_180078BA0(&qword_1801B25D8);\n  Mtx_unlock((_Mtx_t)&unk_1801B2588);\n  sub_1800790C0(&unk_1801B2600);\n  qword_1801B2540 = nullptr;\n  sub_1800DB6D0();\n  cocos2d::CCObject::~CCObject((cocos2d::CCEGLView *)((char *)this + 120));\n  cocos2d::CCEGLViewProtocol::~CCEGLViewProtocol(this);\n}", "assembly": "; \n; cocos2d::CCEGLView::~CCEGLView from 0x1800785b0 to 0x1800786da (298 bytes)\n; \n; 4 xrefs:\n; > sub_180078700 @ 0x18007875e\n; > sub_180078700 @ 0x18007871c\n; > <???> @ 0x18014cf68\n; > <???> @ 0x1801bea1c\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:59 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x1800785b0\npush    rdi                                                            ; +0x5, 0x1800785b5\nsub     rsp, 30h                                                       ; +0x6, 0x1800785b6\nmov     rbx, rcx                                                       ; +0xa, 0x1800785ba\nlea     rax, ??_7CCEGLView@cocos2d@@6BCCEGLViewProtocol@1@@; const cocos2d::CCEGLView::`vftable'{for `cocos2d::CCEGLViewProtocol'} ; +0xd, 0x1800785bd\nmov     [rcx], rax                                                     ; +0x14, 0x1800785c4\nlea     rax, ??_7CCEGLView@cocos2d@@6BCCObject@1@@; const cocos2d::CCEGLView::`vftable'{for `cocos2d::CCObject'} ; +0x17, 0x1800785c7\nmov     [rcx+78h], rax                                                 ; +0x1e, 0x1800785ce\nxor     eax, eax                                                       ; +0x22, 0x1800785d2\nxchg    al, cs:byte_1801B2558                                          ; +0x24, 0x1800785d4\nmov     ecx, cs:idThread; idThread                                     ; +0x2a, 0x1800785da\ntest    ecx, ecx                                                       ; +0x30, 0x1800785e0\njz      short loc_1800785F5                                            ; +0x32, 0x1800785e2\nxor     r9d, r9d; lParam                                               ; +0x34, 0x1800785e4\nxor     r8d, r8d; wParam                                               ; +0x37, 0x1800785e7\nmov     edx, 12h; Msg                                                  ; +0x3a, 0x1800785ea\ncall    cs:PostThreadMessageA                                          ; +0x3f, 0x1800785ef\ncmp     cs:dword_1801B2568, 0                                          ; +0x45, 0x1800785f5\njz      short loc_180078639                                            ; +0x4c, 0x1800785fc\ncall    _Thrd_id                                                       ; +0x4e, 0x1800785fe\ncmp     cs:dword_1801B2568, eax                                        ; +0x53, 0x180078603\njz      loc_1800786CF                                                  ; +0x59, 0x180078609\nmovaps  xmm0, xmmword ptr cs:unk_1801B2560                             ; +0x5f, 0x18007860f\nmovaps  xmmword ptr [rsp+38h+var_18._Hnd], xmm0                        ; +0x66, 0x180078616\nxor     edx, edx; int *                                                ; +0x6b, 0x18007861b\nlea     rcx, [rsp+38h+var_18]; _Thrd_t                                 ; +0x6d, 0x18007861d\ncall    _Thrd_join                                                     ; +0x72, 0x180078622\ntest    eax, eax                                                       ; +0x77, 0x180078627\njnz     loc_1800786C4                                                  ; +0x79, 0x180078629\nxorps   xmm0, xmm0                                                     ; +0x7f, 0x18007862f\nmovaps  xmmword ptr cs:unk_1801B2560, xmm0                             ; +0x82, 0x180078632\nmov     cs:hWnd, 0                                                     ; +0x89, 0x180078639\nlea     rcx, unk_1801B2588; _Mtx_t                                     ; +0x94, 0x180078644\ncall    _Mtx_lock                                                      ; +0x9b, 0x18007864b\ntest    eax, eax                                                       ; +0xa0, 0x180078650\njnz     short loc_1800786CF                                            ; +0xa2, 0x180078652\ncmp     cs:dword_1801B25D4, 7FFFFFFFh                                  ; +0xa4, 0x180078654\njz      short loc_1800786AF                                            ; +0xae, 0x18007865e\nlea     rcx, qword_1801B25D8                                           ; +0xb0, 0x180078660\ncall    sub_180078BA0                                                  ; +0xb7, 0x180078667\nlea     rcx, unk_1801B2588; _Mtx_t                                     ; +0xbc, 0x18007866c\ncall    _Mtx_unlock                                                    ; +0xc3, 0x180078673\nlea     rcx, unk_1801B2600                                             ; +0xc8, 0x180078678\ncall    sub_1800790C0                                                  ; +0xcf, 0x18007867f\nmov     cs:qword_1801B2540, 0                                          ; +0xd4, 0x180078684\ncall    sub_1800DB6D0                                                  ; +0xdf, 0x18007868f\nlea     rcx, [rbx+78h]; this                                           ; +0xe4, 0x180078694\ncall    ??1CCObject@cocos2d@@UEAA@XZ; cocos2d::CCObject::~CCObject(void) ; +0xe8, 0x180078698\nmov     rcx, rbx; this                                                 ; +0xed, 0x18007869d\nmov     rbx, [rsp+38h+arg_0]                                           ; +0xf0, 0x1800786a0\nadd     rsp, 30h                                                       ; +0xf5, 0x1800786a5\npop     rdi                                                            ; +0xf9, 0x1800786a9\njmp     ??1CCEGLViewProtocol@cocos2d@@UEAA@XZ; cocos2d::CCEGLViewProtocol::~CCEGLViewProtocol(void) ; +0xfa, 0x1800786aa\nmov     cs:dword_1801B25D4, 7FFFFFFEh                                  ; +0xff, 0x1800786af\nmov     ecx, 6; int                                                    ; +0x109, 0x1800786b9\ncall    ?_Throw_Cpp_error@std@@YAXH@Z; std::_Throw_Cpp_error(int)      ; +0x10e, 0x1800786be\nint     3; Trap to Debugger                                            ; +0x113, 0x1800786c3\nmov     ecx, 2; int                                                    ; +0x114, 0x1800786c4\ncall    ?_Throw_Cpp_error@std@@YAXH@Z; std::_Throw_Cpp_error(int)      ; +0x119, 0x1800786c9\nint     3; Trap to Debugger                                            ; +0x11e, 0x1800786ce\nmov     ecx, 5; int                                                    ; +0x11f, 0x1800786cf\ncall    ?_Throw_Cpp_error@std@@YAXH@Z; std::_Throw_Cpp_error(int)      ; +0x124, 0x1800786d4\ndb 0CCh                                                                ; +0x129, 0x1800786d9", "xrefs": ["sub_180078700 @ 0x18007875e", "sub_180078700 @ 0x18007871c", "<???> @ 0x18014cf68", "<???> @ 0x1801bea1c"], "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"}