{"type": "func", "start": 4296238900, "end": 4296239388, "name": "LevelCell::onClick", "pseudocode": "// \n// LevelCell::onClick from 0x100136734 to 0x10013691c (488 bytes)\n// \n// 6 xrefs:\n// > LevelCell::loadLocalLevelCell @ 0x100132ff0\n// > LevelCell::loadCustomLevelCell @ 0x100133e3c\n// > LevelCell::loadCustomLevelCell @ 0x100134048\n// > LevelCell::loadCustomLevelCell @ 0x100134124\n// > LevelCell::loadCustomLevelCell @ 0x100134200\n// > LevelCell::loadCustomLevelCell @ 0x1001342c8\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 10:59:27 +0000\n// \n\n__int64 (***__fastcall LevelCell::onClick(__int64 a1, __int64 a2))(void)\n{\n  __int64 (***result)(void); // x0\n  __int64 (*v4)(void); // x5\n  __int64 v6; // x19\n  int v7; // w21\n  _QWORD *v8; // x20\n  char *v9; // x1\n  void *__p[2]; // [xsp+8h] [xbp-38h] BYREF\n  char v11; // [xsp+1Fh] [xbp-21h]\n\n  if ( *(_BYTE *)(a1 + 568) != 1 )\n  {\n    if ( *(_DWORD *)(a1 + 544) == 29 && (*(unsigned int (__fastcall **)(__int64))(*(_QWORD *)a2 + 64LL))(a2) )\n    {\n      result = (__int64 (***)(void))(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a2 + 64LL))(a2);\n      if ( (unsigned int)((_DWORD)result - 1) > 3 )\n        return result;\n      result = *(__int64 (****)(void))(*(_QWORD *)(a1 + 416) + 632LL);\n      if ( !result )\n        return result;\n    }\n    else\n    {\n      if ( *(int *)(*(_QWORD *)(a1 + 560) + 792LL) >= 23 )\n      {\n        sub_100009900(__p, \"Please update your application to download this level.\");\n        v6 = sub_10034A8F8(0, \"Unavailable\", __p, \"Close\", 0);\n        if ( v11 < 0 )\n          operator delete(__p[0]);\n        return (__int64 (***)(void))(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v6 + 1312LL))(v6);\n      }\n      if ( (*(unsigned int (__fastcall **)(__int64))(*(_QWORD *)a2 + 64LL))(a2) != 5\n        && (*(unsigned int (__fastcall **)(__int64))(*(_QWORD *)a2 + 64LL))(a2) != 6 )\n      {\n        v7 = *(_DWORD *)(*(_QWORD *)(a1 + 560) + 1292LL);\n        v8 = (_QWORD *)GameLevelManager::sharedState();\n        if ( v7 < 1 )\n          v9 = *(char **)(a1 + 560);\n        else\n          v9 = LevelCell::recallLevel(a1);\n        return (__int64 (***)(void))GameLevelManager::gotoLevelPage(v8, (__int64)v9);\n      }\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)a2 + 64LL))(a2);\n      result = *(__int64 (****)(void))(*(_QWORD *)(a1 + 416) + 632LL);\n      if ( !result )\n        return result;\n    }\n    v4 = **result;\n    return (__int64 (***)(void))v4();\n  }\n  result = *(__int64 (****)(void))(*(_QWORD *)(a1 + 416) + 632LL);\n  if ( result )\n  {\n    v4 = **result;\n    return (__int64 (***)(void))v4();\n  }\n  return result;\n}", "assembly": "; \n; LevelCell::onClick from 0x100136734 to 0x10013691c (488 bytes)\n; \n; 6 xrefs:\n; > LevelCell::loadLocalLevelCell @ 0x100132ff0\n; > LevelCell::loadCustomLevelCell @ 0x100133e3c\n; > LevelCell::loadCustomLevelCell @ 0x100134048\n; > LevelCell::loadCustomLevelCell @ 0x100134124\n; > LevelCell::loadCustomLevelCell @ 0x100134200\n; > LevelCell::loadCustomLevelCell @ 0x1001342c8\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 10:59:27 +0000\n; \nSUB             SP, SP, #0x50                                          ; +0x0, 0x100136734\nSTP             X22, X21, [SP,#0x40+var_20]                            ; +0x4, 0x100136738\nSTP             X20, X19, [SP,#0x40+var_10]                            ; +0x8, 0x10013673c\nSTP             X29, X30, [SP,#0x40+var_s0]                            ; +0xc, 0x100136740\nADD             X29, SP, #0x40                                         ; +0x10, 0x100136744\nMOV             X19, X0                                                ; +0x14, 0x100136748\nLDRB            W8, [X0,#0x238]                                        ; +0x18, 0x10013674c\nCMP             W8, #1                                                 ; +0x1c, 0x100136750\nB.NE            loc_10013677C                                          ; +0x20, 0x100136754\nLDR             X8, [X19,#0x1A0]                                       ; +0x24, 0x100136758\nLDR             X0, [X8,#0x278]                                        ; +0x28, 0x10013675c\nCBZ             X0, loc_1001368C4                                      ; +0x2c, 0x100136760\nLDR             X8, [X0]                                               ; +0x30, 0x100136764\nLDR             X5, [X8]                                               ; +0x34, 0x100136768\nMOV             X1, X19                                                ; +0x38, 0x10013676c\nMOV             W2, #0x25 ; '%'                                        ; +0x3c, 0x100136770\nMOV             W3, #1                                                 ; +0x40, 0x100136774\nB               loc_1001368AC                                          ; +0x44, 0x100136778\nMOV             X20, X1                                                ; +0x48, 0x10013677c\nLDR             W8, [X19,#0x220]                                       ; +0x4c, 0x100136780\nCMP             W8, #0x1D                                              ; +0x50, 0x100136784\nB.NE            loc_1001367D8                                          ; +0x54, 0x100136788\nLDR             X8, [X20]                                              ; +0x58, 0x10013678c\nLDR             X8, [X8,#0x40]                                         ; +0x5c, 0x100136790\nMOV             X0, X20                                                ; +0x60, 0x100136794\nBLR             X8                                                     ; +0x64, 0x100136798\nCBZ             W0, loc_1001367D8                                      ; +0x68, 0x10013679c\nLDR             X8, [X20]                                              ; +0x6c, 0x1001367a0\nLDR             X8, [X8,#0x40]                                         ; +0x70, 0x1001367a4\nMOV             X0, X20                                                ; +0x74, 0x1001367a8\nBLR             X8                                                     ; +0x78, 0x1001367ac\nSUB             W8, W0, #1                                             ; +0x7c, 0x1001367b0\nCMP             W8, #3                                                 ; +0x80, 0x1001367b4\nB.HI            loc_1001368C4                                          ; +0x84, 0x1001367b8\nLDR             X9, [X19,#0x1A0]                                       ; +0x88, 0x1001367bc\nLDR             X0, [X9,#0x278]                                        ; +0x8c, 0x1001367c0\nCBZ             X0, loc_1001368C4                                      ; +0x90, 0x1001367c4\nADRL            X9, unk_10075E2D0                                      ; +0x94, 0x1001367c8\nLDR             W3, [X9,W8,UXTW#2]                                     ; +0x9c, 0x1001367d0\nB               loc_10013689C                                          ; +0xa0, 0x1001367d4\nLDR             X8, [X19,#0x230]                                       ; +0xa4, 0x1001367d8\nLDR             W8, [X8,#0x318]                                        ; +0xa8, 0x1001367dc\nCMP             W8, #0x17                                              ; +0xac, 0x1001367e0\nB.LT            loc_100136840                                          ; +0xb0, 0x1001367e4\nADRL            X1, aPleaseUpdateYo; \"Please update your application to downl\"... ; +0xb4, 0x1001367e8\nADD             X0, SP, #0x40+__p; int                                 ; +0xbc, 0x1001367f0\nBL              sub_100009900                                          ; +0xc0, 0x1001367f4\nADRL            X1, aUnavailable; \"Unavailable\"                        ; +0xc4, 0x1001367f8\nADRL            X3, aClose; \"Close\"                                    ; +0xcc, 0x100136800\nADD             X2, SP, #0x40+__p                                      ; +0xd4, 0x100136808\nMOV             X0, #0                                                 ; +0xd8, 0x10013680c\nMOV             X4, #0                                                 ; +0xdc, 0x100136810\nBL              sub_10034A8F8                                          ; +0xe0, 0x100136814\nMOV             X19, X0                                                ; +0xe4, 0x100136818\nLDRSB           W8, [SP,#0x40+var_21]                                  ; +0xe8, 0x10013681c\nTBZ             W8, #0x1F, loc_10013682C                               ; +0xec, 0x100136820\nLDR             X0, [SP,#0x40+__p]; __p                                ; +0xf0, 0x100136824\nBL              __ZdlPv; operator delete(void *)                       ; +0xf4, 0x100136828\nLDR             X8, [X19]                                              ; +0xf8, 0x10013682c\nLDR             X8, [X8,#0x520]                                        ; +0xfc, 0x100136830\nMOV             X0, X19                                                ; +0x100, 0x100136834\nBLR             X8                                                     ; +0x104, 0x100136838\nB               loc_1001368C4                                          ; +0x108, 0x10013683c\nLDR             X8, [X20]                                              ; +0x10c, 0x100136840\nLDR             X8, [X8,#0x40]                                         ; +0x110, 0x100136844\nMOV             X0, X20                                                ; +0x114, 0x100136848\nBLR             X8                                                     ; +0x118, 0x10013684c\nCMP             W0, #5                                                 ; +0x11c, 0x100136850\nB.EQ            loc_100136870                                          ; +0x120, 0x100136854\nLDR             X8, [X20]                                              ; +0x124, 0x100136858\nLDR             X8, [X8,#0x40]                                         ; +0x128, 0x10013685c\nMOV             X0, X20                                                ; +0x12c, 0x100136860\nBLR             X8                                                     ; +0x130, 0x100136864\nCMP             W0, #6                                                 ; +0x134, 0x100136868\nB.NE            loc_1001368D8                                          ; +0x138, 0x10013686c\nLDR             X8, [X20]                                              ; +0x13c, 0x100136870\nLDR             X8, [X8,#0x40]                                         ; +0x140, 0x100136874\nMOV             X0, X20                                                ; +0x144, 0x100136878\nBLR             X8                                                     ; +0x148, 0x10013687c\nMOV             X8, X0                                                 ; +0x14c, 0x100136880\nLDR             X9, [X19,#0x1A0]                                       ; +0x150, 0x100136884\nLDR             X0, [X9,#0x278]                                        ; +0x154, 0x100136888\nCBZ             X0, loc_1001368C4                                      ; +0x158, 0x10013688c\nCMP             W8, #5                                                 ; +0x15c, 0x100136890\nMOV             W8, #9                                                 ; +0x160, 0x100136894\nCINC            W3, W8, NE                                             ; +0x164, 0x100136898\nLDR             W2, [X19,#0x220]                                       ; +0x168, 0x10013689c\nLDR             X8, [X0]                                               ; +0x16c, 0x1001368a0\nLDR             X5, [X8]                                               ; +0x170, 0x1001368a4\nMOV             X1, X19                                                ; +0x174, 0x1001368a8\nMOV             X4, #0                                                 ; +0x178, 0x1001368ac\nLDP             X29, X30, [SP,#0x40+var_s0]                            ; +0x17c, 0x1001368b0\nLDP             X20, X19, [SP,#0x40+var_10]                            ; +0x180, 0x1001368b4\nLDP             X22, X21, [SP,#0x40+var_20]                            ; +0x184, 0x1001368b8\nADD             SP, SP, #0x50 ; 'P'                                    ; +0x188, 0x1001368bc\nBR              X5                                                     ; +0x18c, 0x1001368c0\nLDP             X29, X30, [SP,#0x40+var_s0]                            ; +0x190, 0x1001368c4\nLDP             X20, X19, [SP,#0x40+var_10]                            ; +0x194, 0x1001368c8\nLDP             X22, X21, [SP,#0x40+var_20]                            ; +0x198, 0x1001368cc\nADD             SP, SP, #0x50 ; 'P'                                    ; +0x19c, 0x1001368d0\nRET                                                                    ; +0x1a0, 0x1001368d4\nLDR             X8, [X19,#0x230]                                       ; +0x1a4, 0x1001368d8\nLDR             W21, [X8,#0x50C]                                       ; +0x1a8, 0x1001368dc\nBL              GameLevelManager__sharedState                          ; +0x1ac, 0x1001368e0\nMOV             X20, X0                                                ; +0x1b0, 0x1001368e4\nCMP             W21, #1                                                ; +0x1b4, 0x1001368e8\nB.LT            loc_100136900                                          ; +0x1b8, 0x1001368ec\nMOV             X0, X19                                                ; +0x1bc, 0x1001368f0\nBL              LevelCell__recallLevel                                 ; +0x1c0, 0x1001368f4\nMOV             X1, X0                                                 ; +0x1c4, 0x1001368f8\nB               loc_100136904                                          ; +0x1c8, 0x1001368fc\nLDR             X1, [X19,#0x230]                                       ; +0x1cc, 0x100136900\nMOV             X0, X20                                                ; +0x1d0, 0x100136904\nLDP             X29, X30, [SP,#0x40+var_s0]                            ; +0x1d4, 0x100136908\nLDP             X20, X19, [SP,#0x40+var_10]                            ; +0x1d8, 0x10013690c\nLDP             X22, X21, [SP,#0x40+var_20]                            ; +0x1dc, 0x100136910\nADD             SP, SP, #0x50 ; 'P'                                    ; +0x1e0, 0x100136914\nB               GameLevelManager__gotoLevelPage                        ; +0x1e4, 0x100136918", "xrefs": ["LevelCell::loadLocalLevelCell @ 0x100132ff0", "LevelCell::loadCustomLevelCell @ 0x100133e3c", "LevelCell::loadCustomLevelCell @ 0x100134048", "LevelCell::loadCustomLevelCell @ 0x100134124", "LevelCell::loadCustomLevelCell @ 0x100134200", "LevelCell::loadCustomLevelCell @ 0x1001342c8"], "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"}