{"type": "func", "start": 4298765824, "end": 4298766012, "name": "ChallengeNode::onClaimReward", "pseudocode": "// \n// ChallengeNode::onClaimReward from 0x10039f600 to 0x10039f6bc (188 bytes)\n// \n// 1 xrefs:\n// > ChallengeNode::init @ 0x10039f282\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\nvoid __fastcall ChallengeNode::onClaimReward(ChallengeNode *a1, cocos2d::CCObject *a2)\n{\n  cocos2d::CCPoint v2; // xmm0_8\n  ChallengesPage *m_challengesPage; // r15\n  GJChallengeItem *m_challengeItem; // r12\n  unsigned __int64 *v6; // rsi\n  FMODAudioEngine *v7; // rax\n  double v8; // [rsp+8h] [rbp-48h] BYREF\n  char v9; // [rsp+10h] [rbp-40h] BYREF\n  void *v10[7]; // [rsp+11h] [rbp-3Fh] BYREF\n\n  m_challengesPage = a1->m_challengesPage;\n  m_challengeItem = a1->m_challengeItem;\n  v6 = (unsigned __int64 *)((__int64 (__fastcall *)(ChallengeNode *))a1->getPosition)(a1);\n  sub_10028CCE0(&v8, v6, (unsigned __int64 *)&a1->m_unkPoint);\n  ChallengesPage::claimItem(m_challengesPage, (ChallengeNode *)v6, m_challengeItem, v2);\n  v7 = FMODAudioEngine::sharedEngine();\n  v9 = 20;\n  strcpy((char *)v10, \"gold02.ogg\");\n  FMODAudioEngine::playEffect_1(v7, &v9);\n  if ( (v9 & 1) != 0 )\n    operator delete(*(void **)((char *)&v10[1] + 7));\n  ((void (__fastcall *)(cocos2d::CCObject *, _QWORD))a2->__vftable[4].~CCObject)(a2, 0);\n  ((void (__fastcall *)(cocos2d::CCObject *, _QWORD))a2->__vftable[13].copyWithZone)(a2, 0);\n}", "assembly": "; \n; ChallengeNode::onClaimReward from 0x10039f600 to 0x10039f6bc (188 bytes)\n; \n; 1 xrefs:\n; > ChallengeNode::init @ 0x10039f282\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\npush    rbp                                                            ; +0x0, 0x10039f600\nmov     rbp, rsp                                                       ; +0x1, 0x10039f601\npush    r15                                                            ; +0x4, 0x10039f604\npush    r14                                                            ; +0x6, 0x10039f606\npush    r13                                                            ; +0x8, 0x10039f608\npush    r12                                                            ; +0xa, 0x10039f60a\npush    rbx                                                            ; +0xc, 0x10039f60c\nsub     rsp, 28h                                                       ; +0xd, 0x10039f60d\nmov     rbx, rsi                                                       ; +0x11, 0x10039f611\nmov     r14, rdi                                                       ; +0x14, 0x10039f614\nmov     r15, [rdi+140h]                                                ; +0x17, 0x10039f617\nmov     r12, [rdi+148h]                                                ; +0x1e, 0x10039f61e\nmov     rax, [rdi]                                                     ; +0x25, 0x10039f625\ncall    qword ptr [rax+0C0h]                                           ; +0x28, 0x10039f628\nadd     r14, 150h                                                      ; +0x2e, 0x10039f62e\nlea     r13, [rbp+var_48]                                              ; +0x35, 0x10039f635\nmov     rdi, r13                                                       ; +0x39, 0x10039f639\nmov     rsi, rax                                                       ; +0x3c, 0x10039f63c\nmov     rdx, r14                                                       ; +0x3f, 0x10039f63f\ncall    sub_10028CCE0                                                  ; +0x42, 0x10039f642\nmov     rdi, r15                                                       ; +0x47, 0x10039f647\nmov     rdx, r12                                                       ; +0x4a, 0x10039f64a\nmov     rcx, r13                                                       ; +0x4d, 0x10039f64d\ncall    ChallengesPage__claimItem                                      ; +0x50, 0x10039f650\ncall    FMODAudioEngine__sharedEngine                                  ; +0x55, 0x10039f655\nmov     [rbp+var_40], 14h                                              ; +0x5a, 0x10039f65a\nmov     rcx, 6F2E3230646C6F67h                                         ; +0x5e, 0x10039f65e\nmov     [rbp+var_3F], rcx                                              ; +0x68, 0x10039f668\nmov     word ptr [rbp-37h], 6767h                                      ; +0x6c, 0x10039f66c\nmov     byte ptr [rbp-35h], 0                                          ; +0x72, 0x10039f672\nlea     rsi, [rbp+var_40]                                              ; +0x76, 0x10039f676\nmov     rdi, rax                                                       ; +0x7a, 0x10039f67a\ncall    FMODAudioEngine__playEffect_1                                  ; +0x7d, 0x10039f67d\ntest    [rbp+var_40], 1                                                ; +0x82, 0x10039f682\njz      short loc_10039F691                                            ; +0x86, 0x10039f686\nmov     rdi, [rbp+__p]; __p                                            ; +0x88, 0x10039f688\ncall    __ZdlPv; operator delete(void *)                               ; +0x8c, 0x10039f68c\nmov     rax, [rbx]                                                     ; +0x91, 0x10039f691\nmov     rdi, rbx                                                       ; +0x94, 0x10039f694\nxor     esi, esi                                                       ; +0x97, 0x10039f697\ncall    qword ptr [rax+148h]                                           ; +0x99, 0x10039f699\nmov     rax, [rbx]                                                     ; +0x9f, 0x10039f69f\nmov     rdi, rbx                                                       ; +0xa2, 0x10039f6a2\nxor     esi, esi                                                       ; +0xa5, 0x10039f6a5\ncall    qword ptr [rax+410h]                                           ; +0xa7, 0x10039f6a7\nadd     rsp, 28h                                                       ; +0xad, 0x10039f6ad\npop     rbx                                                            ; +0xb1, 0x10039f6b1\npop     r12                                                            ; +0xb2, 0x10039f6b2\npop     r13                                                            ; +0xb4, 0x10039f6b4\npop     r14                                                            ; +0xb6, 0x10039f6b6\npop     r15                                                            ; +0xb8, 0x10039f6b8\npop     rbp                                                            ; +0xba, 0x10039f6ba\nretn                                                                   ; +0xbb, 0x10039f6bb", "xrefs": ["ChallengeNode::init @ 0x10039f282"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}