{"type": "func", "start": 4303766320, "end": 4303766515, "name": "AchievementManager::getAchievementsWithID", "pseudocode": "// \n// AchievementManager::getAchievementsWithID from 0x100864330 to 0x1008643f3 (195 bytes)\n// \n// 7 xrefs:\n// > GJGarageLayer::titleForUnlock @ 0x100358ad9\n// > GJGarageLayer::descriptionForUnlock @ 0x100358c49\n// > GameManager::getUnlockForAchievement @ 0x100361b1f\n// > AchievementManager::isAchievementAvailable @ 0x100864421\n// > AchievementManager::isAchievementAvailable @ 0x100864460\n// > AchievementManager::limitForAchievement @ 0x1008644a3\n// > AchievementManager::limitForAchievement @ 0x1008644b5\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:36:42 +0000\n// \n\n__int64 __fastcall AchievementManager::getAchievementsWithID(__int64 a1, const char *a2)\n{\n  __int64 v2; // rbx\n  size_t v3; // rax\n  size_t v4; // r15\n  char *v5; // r12\n  size_t v6; // r13\n  __int64 result; // rax\n  __int64 v8; // rbx\n  _QWORD __dst[2]; // [rsp+0h] [rbp-40h] BYREF\n  void *__p; // [rsp+10h] [rbp-30h]\n\n  v2 = *(_QWORD *)(a1 + 328);\n  v3 = strlen(a2);\n  if ( v3 >= 0xFFFFFFFFFFFFFFF8LL )\n    sub_100003630();\n  v4 = v3;\n  if ( v3 >= 0x17 )\n  {\n    v6 = 26;\n    if ( (v3 | 7) != 0x17 )\n      v6 = (v3 | 7) + 1;\n    v5 = (char *)operator new(v6);\n    __p = v5;\n    __dst[0] = v6 + 1;\n    __dst[1] = v4;\n    goto LABEL_8;\n  }\n  LOBYTE(__dst[0]) = 2 * v3;\n  v5 = (char *)__dst + 1;\n  if ( v3 )\nLABEL_8:\n    memcpy(v5, a2, v4);\n  v5[v4] = 0;\n  result = cocos2d::CCDictionary::objectForKey(v2, (char *)__dst);\n  if ( (__dst[0] & 1) != 0 )\n  {\n    v8 = result;\n    operator delete(__p);\n    return v8;\n  }\n  return result;\n}", "assembly": "; \n; AchievementManager::getAchievementsWithID from 0x100864330 to 0x1008643f3 (195 bytes)\n; \n; 7 xrefs:\n; > GJGarageLayer::titleForUnlock @ 0x100358ad9\n; > GJGarageLayer::descriptionForUnlock @ 0x100358c49\n; > GameManager::getUnlockForAchievement @ 0x100361b1f\n; > AchievementManager::isAchievementAvailable @ 0x100864421\n; > AchievementManager::isAchievementAvailable @ 0x100864460\n; > AchievementManager::limitForAchievement @ 0x1008644a3\n; > AchievementManager::limitForAchievement @ 0x1008644b5\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:36:42 +0000\n; \npush    rbp                                                            ; +0x0, 0x100864330\nmov     rbp, rsp                                                       ; +0x1, 0x100864331\npush    r15                                                            ; +0x4, 0x100864334\npush    r14                                                            ; +0x6, 0x100864336\npush    r13                                                            ; +0x8, 0x100864338\npush    r12                                                            ; +0xa, 0x10086433a\npush    rbx                                                            ; +0xc, 0x10086433c\nsub     rsp, 18h                                                       ; +0xd, 0x10086433d\nmov     r14, rsi                                                       ; +0x11, 0x100864341\nmov     rbx, [rdi+148h]                                                ; +0x14, 0x100864344\nmov     rdi, rsi; __s                                                  ; +0x1b, 0x10086434b\ncall    _strlen                                                        ; +0x1e, 0x10086434e\ncmp     rax, 0FFFFFFFFFFFFFFF8h                                        ; +0x23, 0x100864353\njnb     loc_1008643EE                                                  ; +0x27, 0x100864357\nmov     r15, rax                                                       ; +0x2d, 0x10086435d\ncmp     rax, 17h                                                       ; +0x30, 0x100864360\njnb     short loc_100864378                                            ; +0x34, 0x100864364\nlea     eax, [r15+r15]                                                 ; +0x36, 0x100864366\nmov     byte ptr [rbp+__dst], al                                       ; +0x3a, 0x10086436a\nlea     r12, [rbp+__dst+1]                                             ; +0x3d, 0x10086436d\ntest    r15, r15                                                       ; +0x41, 0x100864371\njnz     short loc_1008643AB                                            ; +0x44, 0x100864374\njmp     short loc_1008643B9                                            ; +0x46, 0x100864376\nmov     rax, r15                                                       ; +0x48, 0x100864378\nor      rax, 7                                                         ; +0x4b, 0x10086437b\nlea     rcx, [rax+1]                                                   ; +0x4f, 0x10086437f\ncmp     rax, 17h                                                       ; +0x53, 0x100864383\nmov     r13d, 1Ah                                                      ; +0x57, 0x100864387\ncmovnz  r13, rcx                                                       ; +0x5d, 0x10086438d\nmov     rdi, r13; __sz                                                 ; +0x61, 0x100864391\ncall    __Znwm; operator new(ulong)                                    ; +0x64, 0x100864394\nmov     r12, rax                                                       ; +0x69, 0x100864399\nmov     [rbp+__p], rax                                                 ; +0x6c, 0x10086439c\ninc     r13                                                            ; +0x70, 0x1008643a0\nmov     [rbp+__dst], r13                                               ; +0x73, 0x1008643a3\nmov     [rbp+var_38], r15                                              ; +0x77, 0x1008643a7\nmov     rdi, r12; __dst                                                ; +0x7b, 0x1008643ab\nmov     rsi, r14; __src                                                ; +0x7e, 0x1008643ae\nmov     rdx, r15; __n                                                  ; +0x81, 0x1008643b1\ncall    _memcpy                                                        ; +0x84, 0x1008643b4\nmov     byte ptr [r12+r15], 0                                          ; +0x89, 0x1008643b9\nlea     rsi, [rbp+__dst]                                               ; +0x8e, 0x1008643be\nmov     rdi, rbx                                                       ; +0x92, 0x1008643c2\ncall    cocos2d__CCDictionary__objectForKey                            ; +0x95, 0x1008643c5\ntest    byte ptr [rbp+__dst], 1                                        ; +0x9a, 0x1008643ca\njz      short loc_1008643DF                                            ; +0x9e, 0x1008643ce\nmov     rdi, [rbp+__p]; __p                                            ; +0xa0, 0x1008643d0\nmov     rbx, rax                                                       ; +0xa4, 0x1008643d4\ncall    __ZdlPv; operator delete(void *)                               ; +0xa7, 0x1008643d7\nmov     rax, rbx                                                       ; +0xac, 0x1008643dc\nadd     rsp, 18h                                                       ; +0xaf, 0x1008643df\npop     rbx                                                            ; +0xb3, 0x1008643e3\npop     r12                                                            ; +0xb4, 0x1008643e4\npop     r13                                                            ; +0xb6, 0x1008643e6\npop     r14                                                            ; +0xb8, 0x1008643e8\npop     r15                                                            ; +0xba, 0x1008643ea\npop     rbp                                                            ; +0xbc, 0x1008643ec\nretn                                                                   ; +0xbd, 0x1008643ed\ncall    sub_100003630                                                  ; +0xbe, 0x1008643ee", "xrefs": ["GJGarageLayer::titleForUnlock @ 0x100358ad9", "GJGarageLayer::descriptionForUnlock @ 0x100358c49", "GameManager::getUnlockForAchievement @ 0x100361b1f", "AchievementManager::isAchievementAvailable @ 0x100864421", "AchievementManager::isAchievementAvailable @ 0x100864460", "AchievementManager::limitForAchievement @ 0x1008644a3", "AchievementManager::limitForAchievement @ 0x1008644b5"], "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"}