{"type": "func", "start": 4295217024, "end": 4295217113, "name": "GameStatsManager::keyCostForSecretChest", "pseudocode": "// \n// GameStatsManager::keyCostForSecretChest from 0x10003cf80 to 0x10003cfd9 (89 bytes)\n// \n// 1 xrefs:\n// > SecretRewardsLayer::onSelectItem @ 0x1007114ad\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:19:34 +0000\n// \n\n__int64 __fastcall GameStatsManager::keyCostForSecretChest(__int64 a1, int a2)\n{\n  __int64 result; // rax\n\n  result = 1;\n  if ( a2 <= 6000 )\n  {\n    result = 100;\n    if ( a2 <= 5000 )\n    {\n      result = 50;\n      if ( a2 <= 4000 )\n      {\n        result = 25;\n        if ( a2 <= 3000 )\n        {\n          result = 10;\n          if ( a2 <= 2000 )\n            return 4 * (unsigned int)(a2 >= 1001) + 1;\n        }\n      }\n    }\n  }\n  return result;\n}", "assembly": "; \n; GameStatsManager::keyCostForSecretChest from 0x10003cf80 to 0x10003cfd9 (89 bytes)\n; \n; 1 xrefs:\n; > SecretRewardsLayer::onSelectItem @ 0x1007114ad\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:19:34 +0000\n; \npush    rbp                                                            ; +0x0, 0x10003cf80\nmov     rbp, rsp                                                       ; +0x1, 0x10003cf81\nmov     eax, 1                                                         ; +0x4, 0x10003cf84\ncmp     esi, 1770h                                                     ; +0x9, 0x10003cf89\njg      short loc_10003CFD7                                            ; +0xf, 0x10003cf8f\nmov     eax, 64h ; 'd'                                                 ; +0x11, 0x10003cf91\ncmp     esi, 1388h                                                     ; +0x16, 0x10003cf96\njg      short loc_10003CFD7                                            ; +0x1c, 0x10003cf9c\nmov     eax, 32h ; '2'                                                 ; +0x1e, 0x10003cf9e\ncmp     esi, 0FA0h                                                     ; +0x23, 0x10003cfa3\njg      short loc_10003CFD7                                            ; +0x29, 0x10003cfa9\nmov     eax, 19h                                                       ; +0x2b, 0x10003cfab\ncmp     esi, 0BB8h                                                     ; +0x30, 0x10003cfb0\njg      short loc_10003CFD7                                            ; +0x36, 0x10003cfb6\nmov     eax, 0Ah                                                       ; +0x38, 0x10003cfb8\ncmp     esi, 7D0h                                                      ; +0x3d, 0x10003cfbd\njg      short loc_10003CFD7                                            ; +0x43, 0x10003cfc3\nxor     eax, eax                                                       ; +0x45, 0x10003cfc5\ncmp     esi, 3E9h                                                      ; +0x47, 0x10003cfc7\nsetnl   al                                                             ; +0x4d, 0x10003cfcd\nlea     eax, ds:1[rax*4]                                               ; +0x50, 0x10003cfd0\npop     rbp                                                            ; +0x57, 0x10003cfd7\nretn                                                                   ; +0x58, 0x10003cfd8", "xrefs": ["SecretRewardsLayer::onSelectItem @ 0x1007114ad"], "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"}