{"type": "func", "start": 4297610616, "end": 4297610708, "name": "GJBaseGameLayer::countCollectedUserCoins", "pseudocode": "// \n// GJBaseGameLayer::countCollectedUserCoins from 0x100285578 to 0x1002855d4 (92 bytes)\n// \n// 1 xrefs:\n// > PlayLayer::levelComplete @ 0x100142c7c\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 11:01:57 +0000\n// \n\n__int64 __fastcall GJBaseGameLayer::countCollectedUserCoins(__int64 a1)\n{\n  __int64 v1; // x8\n  __int64 v2; // x8\n  __int64 v3; // x19\n  __int64 v4; // x20\n\n  v1 = *(_QWORD *)(a1 + 12592);\n  if ( !v1 )\n    return 0;\n  v2 = *(_QWORD *)(v1 + 56);\n  if ( !v2 )\n    return 0;\n  LODWORD(v3) = 0;\n  do\n  {\n    v4 = *(_QWORD *)(v2 + 288);\n    if ( (*(unsigned int (__fastcall **)(_QWORD))(**(_QWORD **)(v2 + 264) + 1800LL))(*(_QWORD *)(v2 + 264)) == 31 )\n      v3 = (unsigned int)(v3 + 1);\n    else\n      v3 = (unsigned int)v3;\n    v2 = v4;\n  }\n  while ( v4 );\n  return v3;\n}", "assembly": "; \n; GJBaseGameLayer::countCollectedUserCoins from 0x100285578 to 0x1002855d4 (92 bytes)\n; \n; 1 xrefs:\n; > PlayLayer::levelComplete @ 0x100142c7c\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 11:01:57 +0000\n; \nSTP             X20, X19, [SP,#-0x10+var_10]!                          ; +0x0, 0x100285578\nSTP             X29, X30, [SP,#0x10+var_s0]                            ; +0x4, 0x10028557c\nADD             X29, SP, #0x10                                         ; +0x8, 0x100285580\nLDR             X8, [X0,#0x3130]                                       ; +0xc, 0x100285584\nCBZ             X8, loc_1002855C0                                      ; +0x10, 0x100285588\nLDR             X8, [X8,#0x38]                                         ; +0x14, 0x10028558c\nCBZ             X8, loc_1002855C0                                      ; +0x18, 0x100285590\nMOV             W19, #0                                                ; +0x1c, 0x100285594\nLDR             X20, [X8,#0x120]                                       ; +0x20, 0x100285598\nLDR             X0, [X8,#0x108]                                        ; +0x24, 0x10028559c\nLDR             X8, [X0]                                               ; +0x28, 0x1002855a0\nLDR             X8, [X8,#0x708]                                        ; +0x2c, 0x1002855a4\nBLR             X8                                                     ; +0x30, 0x1002855a8\nCMP             W0, #0x1F                                              ; +0x34, 0x1002855ac\nCINC            W19, W19, EQ                                           ; +0x38, 0x1002855b0\nMOV             X8, X20                                                ; +0x3c, 0x1002855b4\nCBNZ            X20, loc_100285598                                     ; +0x40, 0x1002855b8\nB               loc_1002855C4                                          ; +0x44, 0x1002855bc\nMOV             W19, #0                                                ; +0x48, 0x1002855c0\nMOV             X0, X19                                                ; +0x4c, 0x1002855c4\nLDP             X29, X30, [SP,#0x10+var_s0]                            ; +0x50, 0x1002855c8\nLDP             X20, X19, [SP+0x10+var_10],#0x20                       ; +0x54, 0x1002855cc\nRET                                                                    ; +0x58, 0x1002855d0", "xrefs": ["PlayLayer::levelComplete @ 0x100142c7c"], "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"}