{"type": "func", "start": 5730020, "end": 5730228, "name": "CCSpritePart::~CCSpritePart", "pseudocode": "// \n// CCSpritePart::~CCSpritePart from 0x576ee4 to 0x576fb4 (208 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0xb1be8\n// > <???> @ 0x1139910\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 CCSpritePart::~CCSpritePart(CCSpritePart *this)\n{\n  stl::StringData<char>::Internal *m_data; // x2\n  char *v3; // x0\n  unsigned int *v4; // x2\n  int v5; // w1\n\n  m_data = this->m_spriteFrameName.m_data.m_data;\n  this->CCSpritePlus::cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable = (CCSpritePart_vtbl *)&off_1139900;\n  this->CCSpritePlus::cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCRGBAProtocol::__vftable = (cocos2d::CCRGBAProtocol_vtbl *)&off_1139DE8;\n  this->CCSpritePlus::cocos2d::CCSprite::cocos2d::CCTextureProtocol::cocos2d::CCBlendProtocol::__vftable = (cocos2d::CCTextureProtocol_vtbl *)&off_1139E68;\n  v3 = (char *)m_data - 24;\n  if ( (__int64 *)((char *)m_data - 24) != &qword_124B6B0 )\n  {\n    if ( &pthread_create )\n    {\n      v4 = (unsigned int *)((char *)m_data - 8);\n      do\n        v5 = __ldaxr(v4);\n      while ( __stlxr(v5 - 1, v4) );\n    }\n    else\n    {\n      v5 = *((_DWORD *)m_data - 2);\n      *((_DWORD *)m_data - 2) = v5 - 1;\n    }\n    if ( v5 <= 0 )\n      operator delete(v3);\n  }\n  CCSpritePlus::~CCSpritePlus(this);\n  operator delete(this);\n}", "assembly": "; \n; CCSpritePart::~CCSpritePart from 0x576ee4 to 0x576fb4 (208 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0xb1be8\n; > <???> @ 0x1139910\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\nSTP             X29, X30, [SP,#var_30]!                                ; +0x0, 0x576ee4\nMOV             X29, SP                                                ; +0x4, 0x576ee8\nSTP             X19, X20, [SP,#0x30+var_20]                            ; +0x8, 0x576eec\nADRP            X20, #__stack_chk_guard_ptr@PAGE                       ; +0xc, 0x576ef0\nMOV             X19, X0                                                ; +0x10, 0x576ef4\nADRP            X0, #_ZTV12CCSpritePart_ptr@PAGE                       ; +0x14, 0x576ef8\nLDR             X1, [X20,#__stack_chk_guard_ptr@PAGEOFF]; __stack_chk_guard ; +0x18, 0x576efc\nLDR             X0, [X0,#_ZTV12CCSpritePart_ptr@PAGEOFF]; `vtable for'CCSpritePart ... ; +0x1c, 0x576f00\nLDR             X2, [X19,#0x270]                                       ; +0x20, 0x576f04\nLDR             X1, [X1]                                               ; +0x24, 0x576f08\nADD             X4, X0, #0x10                                          ; +0x28, 0x576f0c\nSTR             X1, [X29,#0x30+var_8]                                  ; +0x2c, 0x576f10\nADRP            X1, #off_122EFE8@PAGE                                  ; +0x30, 0x576f14\nADD             X3, X0, #0x4F8                                         ; +0x34, 0x576f18\nSTR             X4, [X19]                                              ; +0x38, 0x576f1c\nADD             X0, X0, #0x578                                         ; +0x3c, 0x576f20\nSTR             X3, [X19,#0x140]                                       ; +0x40, 0x576f24\nSTR             X0, [X19,#0x158]                                       ; +0x44, 0x576f28\nSUB             X0, X2, #0x18; p                                       ; +0x48, 0x576f2c\nLDR             X1, [X1,#off_122EFE8@PAGEOFF]; qword_124B6B0           ; +0x4c, 0x576f30\nCMP             X0, X1                                                 ; +0x50, 0x576f34\nB.NE            loc_576F6C                                             ; +0x54, 0x576f38\nMOV             X0, X19; this                                          ; +0x58, 0x576f3c\nBL              _ZN12CCSpritePlusD2Ev; CCSpritePlus::~CCSpritePlus()   ; +0x5c, 0x576f40\nMOV             X0, X19; p                                             ; +0x60, 0x576f44\nBL              _ZdlPv; operator delete(void *)                        ; +0x64, 0x576f48\nLDR             X20, [X20,#__stack_chk_guard_ptr@PAGEOFF]; __stack_chk_guard ; +0x68, 0x576f4c\nLDR             X1, [X29,#0x30+var_8]                                  ; +0x6c, 0x576f50\nLDR             X0, [X20]                                              ; +0x70, 0x576f54\nCMP             X1, X0                                                 ; +0x74, 0x576f58\nB.NE            loc_576FB0                                             ; +0x78, 0x576f5c\nLDP             X19, X20, [SP,#0x30+var_20]                            ; +0x7c, 0x576f60\nLDP             X29, X30, [SP+0x30+var_30],#0x30                       ; +0x80, 0x576f64\nRET                                                                    ; +0x84, 0x576f68\nADRP            X1, #pthread_create_ptr_0@PAGE                         ; +0x88, 0x576f6c\nLDR             X1, [X1,#pthread_create_ptr_0@PAGEOFF]; pthread_create ; +0x8c, 0x576f70\nCBZ             X1, loc_576FA0                                         ; +0x90, 0x576f74\nSUB             X2, X2, #8                                             ; +0x94, 0x576f78\nLDAXR           W1, [X2]                                               ; +0x98, 0x576f7c\nSUB             W3, W1, #1                                             ; +0x9c, 0x576f80\nSTLXR           W4, W3, [X2]                                           ; +0xa0, 0x576f84\nCBNZ            W4, loc_576F7C                                         ; +0xa4, 0x576f88\nCMP             W1, WZR                                                ; +0xa8, 0x576f8c\nB.GT            loc_576F3C                                             ; +0xac, 0x576f90\nADD             X1, X29, #0x30+var_10                                  ; +0xb0, 0x576f94\nBL              j__ZdlPv; operator delete(void *)                      ; +0xb4, 0x576f98\nB               loc_576F3C                                             ; +0xb8, 0x576f9c\nLDUR            W1, [X2,#-8]                                           ; +0xbc, 0x576fa0\nSUB             W3, W1, #1                                             ; +0xc0, 0x576fa4\nSTUR            W3, [X2,#-8]                                           ; +0xc4, 0x576fa8\nB               loc_576F8C                                             ; +0xc8, 0x576fac\nBL              .__stack_chk_fail                                      ; +0xcc, 0x576fb0", "xrefs": ["<???> @ 0xb1be8", "<???> @ 0x1139910"], "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"}