{"type": "func", "start": 4298029664, "end": 4298029865, "name": "GJPathPage::onUnlock", "pseudocode": "// \n// GJPathPage::onUnlock from 0x1002eba60 to 0x1002ebb29 (201 bytes)\n// \n// 1 xrefs:\n// > GJPathPage::init @ 0x1002eb3cf\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 12:28:23 +0000\n// \n\n__int64 __fastcall GJPathPage::onUnlock(__int64 a1, __m128 a2)\n{\n  unsigned int v2; // r14d\n  __int64 v3; // rax\n  __int64 StoreItem; // r14\n  int v5; // r12d\n  int v6; // r13d\n  __int64 v7; // r15\n  const char *v8; // rsi\n  int Stat; // r15d\n  int v10; // r12d\n  _QWORD *v12; // rax\n  char v13; // [rsp+0h] [rbp-40h] BYREF\n  char v14; // [rsp+1h] [rbp-3Fh] BYREF\n  void *__p; // [rsp+10h] [rbp-30h]\n\n  v2 = *(_DWORD *)(a1 + 688) + 5;\n  v3 = GameStatsManager::sharedState();\n  StoreItem = GameStatsManager::getStoreItem(v3, v2, 0xCu);\n  v5 = *(_DWORD *)(StoreItem + 352);\n  v6 = *(_DWORD *)(StoreItem + 356);\n  v7 = GameStatsManager::sharedState();\n  GJStoreItem::getCurrencyKey((__int64)&v13, StoreItem);\n  if ( (v13 & 1) != 0 )\n    v8 = (const char *)__p;\n  else\n    v8 = &v14;\n  Stat = GameStatsManager::getStat(v7, v8, a2);\n  v10 = v5 - v6;\n  if ( (v13 & 1) != 0 )\n    operator delete(__p);\n  if ( v10 > Stat )\n    return sub_1002EC240(a1, StoreItem);\n  v12 = (_QWORD *)PurchaseItemPopup::create(StoreItem);\n  v12[84] = a1 + 672;\n  return (*(__int64 (__fastcall **)(_QWORD *))(*v12 + 1312LL))(v12);\n}", "assembly": "; \n; GJPathPage::onUnlock from 0x1002eba60 to 0x1002ebb29 (201 bytes)\n; \n; 1 xrefs:\n; > GJPathPage::init @ 0x1002eb3cf\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 12:28:23 +0000\n; \npush    rbp                                                            ; +0x0, 0x1002eba60\nmov     rbp, rsp                                                       ; +0x1, 0x1002eba61\npush    r15                                                            ; +0x4, 0x1002eba64\npush    r14                                                            ; +0x6, 0x1002eba66\npush    r13                                                            ; +0x8, 0x1002eba68\npush    r12                                                            ; +0xa, 0x1002eba6a\npush    rbx                                                            ; +0xc, 0x1002eba6c\nsub     rsp, 18h                                                       ; +0xd, 0x1002eba6d\nmov     rbx, rdi                                                       ; +0x11, 0x1002eba71\nmov     r14d, [rdi+2B0h]                                               ; +0x14, 0x1002eba74\nadd     r14d, 5                                                        ; +0x1b, 0x1002eba7b\ncall    GameStatsManager__sharedState                                  ; +0x1f, 0x1002eba7f\nmov     rdi, rax                                                       ; +0x24, 0x1002eba84\nmov     esi, r14d                                                      ; +0x27, 0x1002eba87\nmov     edx, 0Ch                                                       ; +0x2a, 0x1002eba8a\ncall    GameStatsManager__getStoreItem                                 ; +0x2f, 0x1002eba8f\nmov     r14, rax                                                       ; +0x34, 0x1002eba94\nmov     r12d, [rax+160h]                                               ; +0x37, 0x1002eba97\nmov     r13d, [rax+164h]                                               ; +0x3e, 0x1002eba9e\ncall    GameStatsManager__sharedState                                  ; +0x45, 0x1002ebaa5\nmov     r15, rax                                                       ; +0x4a, 0x1002ebaaa\nlea     rdi, [rbp+var_40]                                              ; +0x4d, 0x1002ebaad\nmov     rsi, r14                                                       ; +0x51, 0x1002ebab1\ncall    GJStoreItem__getCurrencyKey                                    ; +0x54, 0x1002ebab4\ntest    [rbp+var_40], 1                                                ; +0x59, 0x1002ebab9\njz      short loc_1002EBAC5                                            ; +0x5d, 0x1002ebabd\nmov     rsi, [rbp+__p]                                                 ; +0x5f, 0x1002ebabf\njmp     short loc_1002EBAC9                                            ; +0x63, 0x1002ebac3\nlea     rsi, [rbp+var_3F]                                              ; +0x65, 0x1002ebac5\nmov     rdi, r15                                                       ; +0x69, 0x1002ebac9\ncall    GameStatsManager__getStat                                      ; +0x6c, 0x1002ebacc\nmov     r15d, eax                                                      ; +0x71, 0x1002ebad1\nsub     r12d, r13d                                                     ; +0x74, 0x1002ebad4\ntest    [rbp+var_40], 1                                                ; +0x77, 0x1002ebad7\njz      short loc_1002EBAE6                                            ; +0x7b, 0x1002ebadb\nmov     rdi, [rbp+__p]; __p                                            ; +0x7d, 0x1002ebadd\ncall    __ZdlPv; operator delete(void *)                               ; +0x81, 0x1002ebae1\ncmp     r12d, r15d                                                     ; +0x86, 0x1002ebae6\njle     short loc_1002EBAF8                                            ; +0x89, 0x1002ebae9\nmov     rdi, rbx                                                       ; +0x8b, 0x1002ebaeb\nmov     rsi, r14                                                       ; +0x8e, 0x1002ebaee\ncall    sub_1002EC240                                                  ; +0x91, 0x1002ebaf1\njmp     short loc_1002EBB1A                                            ; +0x96, 0x1002ebaf6\nmov     rdi, r14                                                       ; +0x98, 0x1002ebaf8\ncall    PurchaseItemPopup__create                                      ; +0x9b, 0x1002ebafb\nadd     rbx, 2A0h                                                      ; +0xa0, 0x1002ebb00\nmov     [rax+2A0h], rbx                                                ; +0xa7, 0x1002ebb07\nmov     rcx, [rax]                                                     ; +0xae, 0x1002ebb0e\nmov     rdi, rax                                                       ; +0xb1, 0x1002ebb11\ncall    qword ptr [rcx+520h]                                           ; +0xb4, 0x1002ebb14\nadd     rsp, 18h                                                       ; +0xba, 0x1002ebb1a\npop     rbx                                                            ; +0xbe, 0x1002ebb1e\npop     r12                                                            ; +0xbf, 0x1002ebb1f\npop     r13                                                            ; +0xc1, 0x1002ebb21\npop     r14                                                            ; +0xc3, 0x1002ebb23\npop     r15                                                            ; +0xc5, 0x1002ebb25\npop     rbp                                                            ; +0xc7, 0x1002ebb27\nretn                                                                   ; +0xc8, 0x1002ebb28", "xrefs": ["GJPathPage::init @ 0x1002eb3cf"], "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"}