{"type": "func", "start": 6919980, "end": 6920300, "name": "FLAlertLayer::addCloseButton", "pseudocode": "// \n// FLAlertLayer::addCloseButton from 0x69972c to 0x69986c (320 bytes)\n// \n// 4 xrefs:\n// > LevelInfoLayer::onPlay @ 0x7e7bf4\n// > EditLevelLayer::onTest @ 0x7ee144\n// > EditLevelLayer::onPlay @ 0x7eee2c\n// > <???> @ 0x78ca0\n// \n// This function is hookable on this platform (idp: arm, 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 12:50:39 +0000\n// \n\n__int64 __fastcall FLAlertLayer::addCloseButton(FLAlertLayer *this)\n{\n  cocos2d::CCDirector *v2; // x0\n  const char *v3; // x1\n  __int64 v4; // x19\n  __int64 v5; // x19\n  float v6; // s1\n  cocos2d::CCNode *v7; // x23\n  float v8; // s0\n  void (__fastcall *v9)(__int64, __int64 *); // x20\n  __int64 v11; // [xsp+50h] [xbp+50h] BYREF\n  _BYTE v12[8]; // [xsp+58h] [xbp+58h] BYREF\n  __int64 v13; // [xsp+60h] [xbp+60h] BYREF\n\n  v2 = (cocos2d::CCDirector *)cocos2d::CCDirector::sharedDirector(_stack_chk_guard);\n  cocos2d::CCDirector::getWinSize(&v11, v2);\n  v4 = cocos2d::CCSprite::createWithSpriteFrameName((cocos2d::CCSprite *)\"GJ_closeBtn_001.png\", v3);\n  (*(void (__fastcall **)(__int64, float))(*(_QWORD *)v4 + 160LL))(v4, 0.7);\n  v5 = CCMenuItemSpriteExtra::create(v4, 0, (__int64)this, (__int64)FLAlertLayer::onButton, 0);\n  CCMenuItemSpriteExtra::setSizeMult(v5, 1.2);\n  (*(void (__fastcall **)(_QWORD, __int64))(**((_QWORD **)this + 69) + 456LL))(*((_QWORD *)this + 69), v5);\n  v6 = *((float *)this + 163);\n  v7 = *((cocos2d::CCNode **)this + 69);\n  v8 = *((float *)this + 162) * 0.5;\n  v9 = *(void (__fastcall **)(__int64, __int64 *))(*(_QWORD *)v5 + 184LL);\n  cocos2d::CCPoint::CCPoint(\n    (cocos2d::CCPoint *)v12,\n    5.0 - (float)(v8 - (float)(*(float *)&v11 * 0.5)),\n    (float)((float)(v6 * 0.5) + (float)(*((float *)&v11 + 1) * 0.5)) - 5.0);\n  cocos2d::CCNode::convertToNodeSpace(&v13, v7, (const cocos2d::CCPoint *)v12);\n  v9(v5, &v13);\n  (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v5 + 72LL))(v5, 2);\n  return v5;\n}", "assembly": "; \n; FLAlertLayer::addCloseButton from 0x69972c to 0x69986c (320 bytes)\n; \n; 4 xrefs:\n; > LevelInfoLayer::onPlay @ 0x7e7bf4\n; > EditLevelLayer::onTest @ 0x7ee144\n; > EditLevelLayer::onPlay @ 0x7eee2c\n; > <???> @ 0x78ca0\n; \n; This function is hookable on this platform (idp: arm, 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 12:50:39 +0000\n; \nSTP             X29, X30, [SP,#var_70]!                                ; +0x0, 0x69972c\nMOV             X29, SP                                                ; +0x4, 0x699730\nSTP             X21, X22, [SP,#0x70+var_50]                            ; +0x8, 0x699734\nADRP            X21, #__stack_chk_guard_ptr@PAGE                       ; +0xc, 0x699738\nSTR             X23, [SP,#0x70+var_40]                                 ; +0x10, 0x69973c\nSTP             X19, X20, [SP,#0x70+var_60]                            ; +0x14, 0x699740\nMOV             X20, X0                                                ; +0x18, 0x699744\nADD             X23, X29, #0x70+var_18                                 ; +0x1c, 0x699748\nLDR             X21, [X21,#__stack_chk_guard_ptr@PAGEOFF]; __stack_chk_guard ; +0x20, 0x69974c\nADD             X22, X29, #0x70+var_10                                 ; +0x24, 0x699750\nLDR             X0, [X21]; this                                        ; +0x28, 0x699754\nSTR             X0, [X29,#0x70+var_8]                                  ; +0x2c, 0x699758\nBL              _ZN7cocos2d10CCDirector14sharedDirectorEv; cocos2d::CCDirector::sharedDirector(void) ; +0x30, 0x69975c\nADD             X8, X29, #0x70+var_20                                  ; +0x34, 0x699760\nBL              _ZN7cocos2d10CCDirector10getWinSizeEv; cocos2d::CCDirector::getWinSize(void) ; +0x38, 0x699764\nADRL            X0, aGjClosebtn001P; \"GJ_closeBtn_001.png\"             ; +0x3c, 0x699768\nBL              _ZN7cocos2d8CCSprite25createWithSpriteFrameNameEPKc; cocos2d::CCSprite::createWithSpriteFrameName(char const*) ; +0x44, 0x699770\nLDR             X1, [X0]                                               ; +0x48, 0x699774\nLDR             S0, =0x3F333333                                        ; +0x4c, 0x699778\nMOV             X19, X0                                                ; +0x50, 0x69977c\nLDR             X1, [X1,#0xA0]                                         ; +0x54, 0x699780\nBLR             X1                                                     ; +0x58, 0x699784\nADRP            X3, #_ZN12FLAlertLayer8onButtonEPN7cocos2d8CCObjectE_ptr@PAGE ; +0x5c, 0x699788\nMOV             X4, #0                                                 ; +0x60, 0x69978c\nMOV             X2, X20                                                ; +0x64, 0x699790\nMOV             X1, #0                                                 ; +0x68, 0x699794\nMOV             X0, X19                                                ; +0x6c, 0x699798\nLDR             X3, [X3,#_ZN12FLAlertLayer8onButtonEPN7cocos2d8CCObjectE_ptr@PAGEOFF]; FLAlertLayer::onButton(cocos2d::CCObject *) ... ; +0x70, 0x69979c\nBL              _ZN21CCMenuItemSpriteExtra6createEPN7cocos2d6CCNodeES2_PNS0_8CCObjectEMS3_FvS4_E; CCMenuItemSpriteExtra::create(cocos2d::CCNode *,cocos2d::CCNode *,cocos2d::CCObject *,void (cocos2d::CCObject::*)(cocos2d::CCObject *)) ; +0x74, 0x6997a0\nMOV             X19, X0                                                ; +0x78, 0x6997a4\nLDR             S0, flt_699870; float                                  ; +0x7c, 0x6997a8\nBL              _ZN21CCMenuItemSpriteExtra11setSizeMultEf; CCMenuItemSpriteExtra::setSizeMult(float) ; +0x80, 0x6997ac\nLDR             X2, [X20,#0x228]                                       ; +0x84, 0x6997b0\nMOV             X1, X19                                                ; +0x88, 0x6997b4\nMOV             X0, X2                                                 ; +0x8c, 0x6997b8\nLDR             X2, [X2]                                               ; +0x90, 0x6997bc\nLDR             X2, [X2,#0x1C8]                                        ; +0x94, 0x6997c0\nBLR             X2                                                     ; +0x98, 0x6997c4\nSTR             X23, [X29,#0x70+var_28]                                ; +0x9c, 0x6997c8\nFMOV            S2, #0.5                                               ; +0xa0, 0x6997cc\nLDR             X2, [X19]                                              ; +0xa4, 0x6997d0\nLDR             S0, [X20,#0x288]                                       ; +0xa8, 0x6997d4\nMOV             X0, X23; this                                          ; +0xac, 0x6997d8\nLDR             S1, [X20,#0x28C]                                       ; +0xb0, 0x6997dc\nLDR             X23, [X20,#0x228]                                      ; +0xb4, 0x6997e0\nFMUL            S0, S0, S2                                             ; +0xb8, 0x6997e4\nLDR             X20, [X2,#0xB8]                                        ; +0xbc, 0x6997e8\nFMUL            S1, S1, S2                                             ; +0xc0, 0x6997ec\nLDR             S3, [X29,#0x70+var_20]                                 ; +0xc4, 0x6997f0\nFNMSUB          S0, S3, S2, S0                                         ; +0xc8, 0x6997f4\nLDR             S3, [X29,#0x70+var_1C]                                 ; +0xcc, 0x6997f8\nFMADD           S3, S3, S2, S1                                         ; +0xd0, 0x6997fc\nFMOV            S1, #5.0                                               ; +0xd4, 0x699800\nFADD            S0, S0, S1; float                                      ; +0xd8, 0x699804\nFSUB            S1, S3, S1; float                                      ; +0xdc, 0x699808\nBL              _ZN7cocos2d7CCPointC1Eff; cocos2d::CCPoint::CCPoint(float,float) ; +0xe0, 0x69980c\nLDR             X1, [X29,#0x70+var_28]; cocos2d::CCPoint *             ; +0xe4, 0x699810\nMOV             X8, X22                                                ; +0xe8, 0x699814\nMOV             X0, X23; this                                          ; +0xec, 0x699818\nBL              _ZN7cocos2d6CCNode18convertToNodeSpaceERKNS_7CCPointE; cocos2d::CCNode::convertToNodeSpace(cocos2d::CCPoint const&) ; +0xf0, 0x69981c\nMOV             X0, X19                                                ; +0xf4, 0x699820\nMOV             X1, X22                                                ; +0xf8, 0x699824\nBLR             X20                                                    ; +0xfc, 0x699828\nLDR             X2, [X19]                                              ; +0x100, 0x69982c\nMOV             X0, X19                                                ; +0x104, 0x699830\nMOV             W1, #2                                                 ; +0x108, 0x699834\nLDR             X2, [X2,#0x48]                                         ; +0x10c, 0x699838\nBLR             X2                                                     ; +0x110, 0x69983c\nLDR             X2, [X29,#0x70+var_8]                                  ; +0x114, 0x699840\nMOV             X0, X19                                                ; +0x118, 0x699844\nLDR             X1, [X21]                                              ; +0x11c, 0x699848\nCMP             X2, X1                                                 ; +0x120, 0x69984c\nB.NE            loc_699868                                             ; +0x124, 0x699850\nLDP             X19, X20, [SP,#0x70+var_60]                            ; +0x128, 0x699854\nLDP             X21, X22, [SP,#0x70+var_50]                            ; +0x12c, 0x699858\nLDR             X23, [SP,#0x70+var_40]                                 ; +0x130, 0x69985c\nLDP             X29, X30, [SP+0x70+var_70],#0x70                       ; +0x134, 0x699860\nRET                                                                    ; +0x138, 0x699864\nBL              .__stack_chk_fail                                      ; +0x13c, 0x699868", "xrefs": ["LevelInfoLayer::onPlay @ 0x7e7bf4", "EditLevelLayer::onTest @ 0x7ee144", "EditLevelLayer::onPlay @ 0x7eee2c", "<???> @ 0x78ca0"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "arm", "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"}