{"type": "func", "start": 5369082784, "end": 5369083069, "name": "FLAlertLayer::addCloseButton", "pseudocode": "// \n// FLAlertLayer::addCloseButton from 0x14005b3a0 to 0x14005b4bd (285 bytes)\n// \n// 3 xrefs:\n// > EditLevelLayer::onPlay @ 0x14017b277\n// > LevelInfoLayer::onPlay @ 0x140421a59\n// > <???> @ 0x1409106f4\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:25:42 +0000\n// \n\ncocos2d::CCObject *__fastcall FLAlertLayer::addCloseButton(__int64 a1)\n{\n  __int64 v2; // rax\n  struct cocos2d::CCSprite *v3; // rax\n  int v4; // ebx\n  cocos2d::CCObject *v5; // r14\n  __int64 v6; // rdi\n  __int64 v7; // rbx\n  __int64 v8; // rax\n  __int64 v9; // rax\n  float v11; // [rsp+40h] [rbp+8h] BYREF\n  float v12; // [rsp+44h] [rbp+Ch]\n  char v13; // [rsp+48h] [rbp+10h] BYREF\n  char v14; // [rsp+50h] [rbp+18h] BYREF\n\n  v2 = cocos2d::CCDirector::sharedDirector();\n  cocos2d::CCDirector::getWinSize(v2, &v11);\n  v3 = cocos2d::CCSprite::createWithSpriteFrameName(\"GJ_closeBtn_001.png\");\n  v4 = (int)v3;\n  (*(void (__fastcall **)(struct cocos2d::CCSprite *))(*(_QWORD *)v3 + 160LL))(v3);\n  v5 = CCMenuItemSpriteExtra::create(v4, 0, a1, (__int64)FLAlertLayer::onButton);\n  *((_DWORD *)v5 + 93) = 1067030938;\n  (*(void (__fastcall **)(_QWORD, cocos2d::CCObject *))(**(_QWORD **)(a1 + 552) + 464LL))(*(_QWORD *)(a1 + 552), v5);\n  v6 = *(_QWORD *)v5;\n  v7 = *(_QWORD *)(a1 + 552);\n  cocos2d::CCPoint::CCPoint(\n    (cocos2d::CCPoint *)&v13,\n    (float)((float)(v11 * 0.5) - (float)(*(float *)(a1 + 648) * 0.5)) + 5.0,\n    (float)((float)(*(float *)(a1 + 652) * 0.5) + (float)(v12 * 0.5)) - 5.0);\n  cocos2d::CCNode::convertToNodeSpace(v7, &v14, v8);\n  (*(void (__fastcall **)(cocos2d::CCObject *, __int64))(v6 + 184))(v5, v9);\n  (*(void (__fastcall **)(cocos2d::CCObject *, __int64))(*(_QWORD *)v5 + 64LL))(v5, 2);\n  return v5;\n}", "assembly": "; \n; FLAlertLayer::addCloseButton from 0x14005b3a0 to 0x14005b4bd (285 bytes)\n; \n; 3 xrefs:\n; > EditLevelLayer::onPlay @ 0x14017b277\n; > LevelInfoLayer::onPlay @ 0x140421a59\n; > <???> @ 0x1409106f4\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:25:42 +0000\n; \nmov     [rsp+arg_18], rbx                                              ; +0x0, 0x14005b3a0\npush    rsi                                                            ; +0x5, 0x14005b3a5\npush    rdi                                                            ; +0x6, 0x14005b3a6\npush    r14                                                            ; +0x7, 0x14005b3a7\nsub     rsp, 20h                                                       ; +0x9, 0x14005b3a9\nmov     rsi, rcx                                                       ; +0xd, 0x14005b3ad\ncall    cs:?sharedDirector@CCDirector@cocos2d@@SAPEAV12@XZ; cocos2d::CCDirector::sharedDirector(void) ; +0x10, 0x14005b3b0\nmov     rcx, rax                                                       ; +0x16, 0x14005b3b6\nlea     rdx, [rsp+38h+arg_0]                                           ; +0x19, 0x14005b3b9\ncall    cs:?getWinSize@CCDirector@cocos2d@@QEAA?AVCCSize@2@XZ; cocos2d::CCDirector::getWinSize(void) ; +0x1e, 0x14005b3be\nlea     rcx, aGjClosebtn001P; \"GJ_closeBtn_001.png\"                    ; +0x24, 0x14005b3c4\ncall    cs:?createWithSpriteFrameName@CCSprite@cocos2d@@SAPEAV12@PEBD@Z; cocos2d::CCSprite::createWithSpriteFrameName(char const *) ; +0x2b, 0x14005b3cb\nmovss   xmm1, cs:dword_140834FAC                                       ; +0x31, 0x14005b3d1\nmov     rcx, rax                                                       ; +0x39, 0x14005b3d9\nmov     rbx, rax                                                       ; +0x3c, 0x14005b3dc\nmov     rdx, [rax]                                                     ; +0x3f, 0x14005b3df\ncall    qword ptr [rdx+0A0h]                                           ; +0x42, 0x14005b3e2\nlea     r9, FLAlertLayer__onButton                                     ; +0x48, 0x14005b3e8\nmov     r8, rsi                                                        ; +0x4f, 0x14005b3ef\nxor     edx, edx                                                       ; +0x52, 0x14005b3f2\nmov     rcx, rbx                                                       ; +0x54, 0x14005b3f4\ncall    CCMenuItemSpriteExtra__create                                  ; +0x57, 0x14005b3f7\nmov     r14, rax                                                       ; +0x5c, 0x14005b3fc\nmov     dword ptr [rax+174h], 3F99999Ah                                ; +0x5f, 0x14005b3ff\nmov     rcx, [rsi+228h]                                                ; +0x69, 0x14005b409\nmov     rdx, [rcx]                                                     ; +0x70, 0x14005b410\nmov     r8, [rdx+1D0h]                                                 ; +0x73, 0x14005b413\nmov     rdx, rax                                                       ; +0x7a, 0x14005b41a\ncall    r8                                                             ; +0x7d, 0x14005b41d\nmovss   xmm4, cs:dword_140834F20                                       ; +0x80, 0x14005b420\nlea     rcx, [rsp+38h+arg_8]                                           ; +0x88, 0x14005b428\nmovss   xmm0, [rsp+38h+arg_4]                                          ; +0x8d, 0x14005b42d\nmovss   xmm2, dword ptr [rsi+28Ch]                                     ; +0x93, 0x14005b433\nmovss   xmm1, [rsp+38h+arg_0]                                          ; +0x9b, 0x14005b43b\nmov     rdi, [r14]                                                     ; +0xa1, 0x14005b441\nmov     rbx, [rsi+228h]                                                ; +0xa4, 0x14005b444\nmulss   xmm0, xmm4                                                     ; +0xab, 0x14005b44b\nmulss   xmm2, xmm4                                                     ; +0xaf, 0x14005b44f\nmulss   xmm1, xmm4                                                     ; +0xb3, 0x14005b453\naddss   xmm2, xmm0                                                     ; +0xb7, 0x14005b457\nmovss   xmm0, dword ptr [rsi+288h]                                     ; +0xbb, 0x14005b45b\nmulss   xmm0, xmm4                                                     ; +0xc3, 0x14005b463\nsubss   xmm2, cs:flt_140835470                                         ; +0xc7, 0x14005b467\nsubss   xmm1, xmm0                                                     ; +0xcf, 0x14005b46f\naddss   xmm1, cs:flt_140835470                                         ; +0xd3, 0x14005b473\ncall    cs:??0CCPoint@cocos2d@@QEAA@MM@Z; cocos2d::CCPoint::CCPoint(float,float) ; +0xdb, 0x14005b47b\nlea     rdx, [rsp+38h+arg_10]                                          ; +0xe1, 0x14005b481\nmov     rcx, rbx                                                       ; +0xe6, 0x14005b486\nmov     r8, rax                                                        ; +0xe9, 0x14005b489\ncall    cs:?convertToNodeSpace@CCNode@cocos2d@@QEAA?AVCCPoint@2@AEBV32@@Z; cocos2d::CCNode::convertToNodeSpace(cocos2d::CCPoint const &) ; +0xec, 0x14005b48c\nmov     rdx, rax                                                       ; +0xf2, 0x14005b492\nmov     rcx, r14                                                       ; +0xf5, 0x14005b495\ncall    qword ptr [rdi+0B8h]                                           ; +0xf8, 0x14005b498\nmov     rax, [r14]                                                     ; +0xfe, 0x14005b49e\nmov     edx, 2                                                         ; +0x101, 0x14005b4a1\nmov     rcx, r14                                                       ; +0x106, 0x14005b4a6\ncall    qword ptr [rax+40h]                                            ; +0x109, 0x14005b4a9\nmov     rbx, [rsp+38h+arg_18]                                          ; +0x10c, 0x14005b4ac\nmov     rax, r14                                                       ; +0x111, 0x14005b4b1\nadd     rsp, 20h                                                       ; +0x114, 0x14005b4b4\npop     r14                                                            ; +0x118, 0x14005b4b8\npop     rdi                                                            ; +0x11a, 0x14005b4ba\npop     rsi                                                            ; +0x11b, 0x14005b4bb\nretn                                                                   ; +0x11c, 0x14005b4bc", "xrefs": ["EditLevelLayer::onPlay @ 0x14017b277", "LevelInfoLayer::onPlay @ 0x140421a59", "<???> @ 0x1409106f4"], "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"}