{"type": "func", "start": 10933640, "end": 10934124, "name": "GJPathPage::unlockAnimationStep2", "pseudocode": "// \n// GJPathPage::unlockAnimationStep2 from 0xa6d588 to 0xa6d76c (484 bytes)\n// \n// 3 xrefs:\n// > <???> @ 0x53fd0\n// > GJPathPage::playUnlockAnimation @ 0xa6e2a8\n// > <???> @ 0x122ab28\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 GJPathPage::unlockAnimationStep2(GJPathPage *a1)\n{\n  cocos2d::CCDirector *v2; // x0\n  cocos2d::CCParticleSystemQuad *v3; // x19\n  void (__fastcall *setPosition)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x23\n  void (__fastcall *setStartColor)(cocos2d::CCParticleSystem *__hidden, const cocos2d::ccColor4F *); // x23\n  float v6; // s0\n  float v7; // s1\n  int v8; // s2\n  int v9; // s3\n  int m_pathNumber; // w0\n  void (__fastcall *setEndColor)(cocos2d::CCParticleSystem *__hidden, const cocos2d::ccColor4F *); // x22\n  float v12; // s0\n  float v13; // s1\n  int v14; // s2\n  int v15; // s3\n  void *v16; // x0\n  unsigned int *v17; // x2\n  int v18; // w1\n  float v19; // [xsp+48h] [xbp+48h]\n  float v20; // [xsp+4Ch] [xbp+4Ch]\n  __int64 v21; // [xsp+50h] [xbp+50h] BYREF\n  cocos2d::CCPoint v22; // [xsp+58h] [xbp+58h] BYREF\n  int v23; // [xsp+60h] [xbp+60h]\n  int v24; // [xsp+64h] [xbp+64h]\n\n  v2 = cocos2d::CCDirector::sharedDirector();\n  cocos2d::CCDirector::getWinSize(v2);\n  sub_D153B8(\n    (int)&v21,\n    \"84a0.97a1a0.16a72a180a180a29a0a11a0a0a0a0a0a0a0a2a1a0a0a1a0a0a0a0a0a1a0a1a1a0a0a1a0a0.568627a0a0a0a1a0a0.8a0a0.2a0a1\"\n    \"50a0a0a0a0a0a1a2a1a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0\");\n  v3 = GameToolbox::particleFromString(&v21, nullptr, 0);\n  v3->setAutoRemoveOnFinish(v3, 1);\n  a1->addChild_0(a1, v3, 11);\n  v3->setScale(v3, 2.0);\n  cocos2d::CCParticleSystem::resetSystem(v3);\n  setPosition = v3->setPosition;\n  cocos2d::CCPoint::CCPoint(&v22, v19 * 0.5, v20 * 0.5);\n  setPosition(v3, &v22);\n  setStartColor = v3->setStartColor;\n  darkColorForPath(a1->m_pathNumber);\n  v22.x = v6;\n  v22.y = v7;\n  v23 = v8;\n  v24 = v9;\n  setStartColor(v3, (const cocos2d::ccColor4F *)&v22);\n  m_pathNumber = a1->m_pathNumber;\n  setEndColor = v3->setEndColor;\n  lightColorForPath(m_pathNumber);\n  v22.x = v12;\n  v22.y = v13;\n  v23 = v14;\n  v24 = v15;\n  setEndColor(v3, (const cocos2d::ccColor4F *)&v22);\n  v16 = (void *)(v21 - 24);\n  if ( (__int64 *)(v21 - 24) != &qword_124B6B0 )\n  {\n    if ( &pthread_create )\n    {\n      v17 = (unsigned int *)(v21 - 8);\n      do\n        v18 = __ldaxr(v17);\n      while ( __stlxr(v18 - 1, v17) );\n    }\n    else\n    {\n      v18 = *(_DWORD *)(v21 - 8);\n      *(_DWORD *)(v21 - 8) = v18 - 1;\n    }\n    if ( v18 <= 0 )\n      operator delete(v16);\n  }\n}", "assembly": "; \n; GJPathPage::unlockAnimationStep2 from 0xa6d588 to 0xa6d76c (484 bytes)\n; \n; 3 xrefs:\n; > <???> @ 0x53fd0\n; > GJPathPage::playUnlockAnimation @ 0xa6e2a8\n; > <???> @ 0x122ab28\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\nSTP             X29, X30, [SP,#var_70]!                                ; +0x0, 0xa6d588\nMOV             X29, SP                                                ; +0x4, 0xa6d58c\nSTP             X21, X22, [SP,#0x70+var_50]                            ; +0x8, 0xa6d590\nADRP            X21, #__stack_chk_guard_ptr@PAGE                       ; +0xc, 0xa6d594\nMOV             X22, X0                                                ; +0x10, 0xa6d598\nSTP             X19, X20, [SP,#0x70+var_60]                            ; +0x14, 0xa6d59c\nSTR             X23, [SP,#0x70+var_40]                                 ; +0x18, 0xa6d5a0\nADD             X19, X29, #0x70+var_20                                 ; +0x1c, 0xa6d5a4\nLDR             X0, [X21,#__stack_chk_guard_ptr@PAGEOFF]; __stack_chk_guard ; +0x20, 0xa6d5a8\nADD             X20, X29, #0x70+var_18                                 ; +0x24, 0xa6d5ac\nLDR             X0, [X0]; this                                         ; +0x28, 0xa6d5b0\nSTR             X0, [X29,#0x70+var_8]                                  ; +0x2c, 0xa6d5b4\nBL              _ZN7cocos2d10CCDirector14sharedDirectorEv; cocos2d::CCDirector::sharedDirector(void) ; +0x30, 0xa6d5b8\nADD             X8, X29, #0x70+var_28                                  ; +0x34, 0xa6d5bc\nBL              _ZN7cocos2d10CCDirector10getWinSizeEv; cocos2d::CCDirector::getWinSize(void) ; +0x38, 0xa6d5c0\nADRP            X1, #a84a097a1a016a7@PAGE; \"84a0.97a1a0.16a72a180a180a29a0a11a0a0a0\"... ; +0x3c, 0xa6d5c4\nMOV             X2, X20                                                ; +0x40, 0xa6d5c8\nADD             X1, X1, #a84a097a1a016a7@PAGEOFF; \"84a0.97a1a0.16a72a180a180a29a0a11a0a0a0\"... ; +0x44, 0xa6d5cc\nMOV             X0, X19; int                                           ; +0x48, 0xa6d5d0\nBL              sub_D153B8                                             ; +0x4c, 0xa6d5d4\nMOV             X0, X19                                                ; +0x50, 0xa6d5d8\nMOV             X1, #0                                                 ; +0x54, 0xa6d5dc\nMOV             W2, #0                                                 ; +0x58, 0xa6d5e0\nBL              _ZN11GameToolbox18particleFromStringERKSsPN7cocos2d20CCParticleSystemQuadEb; GameToolbox::particleFromString(std::string const&,cocos2d::CCParticleSystemQuad *,bool) ; +0x5c, 0xa6d5e4\nLDR             X2, [X0]                                               ; +0x60, 0xa6d5e8\nMOV             W1, #1                                                 ; +0x64, 0xa6d5ec\nMOV             X19, X0                                                ; +0x68, 0xa6d5f0\nLDR             X2, [X2,#0x620]                                        ; +0x6c, 0xa6d5f4\nBLR             X2                                                     ; +0x70, 0xa6d5f8\nLDR             X3, [X22]                                              ; +0x74, 0xa6d5fc\nMOV             X0, X22                                                ; +0x78, 0xa6d600\nMOV             X1, X19                                                ; +0x7c, 0xa6d604\nMOV             W2, #0xB                                               ; +0x80, 0xa6d608\nLDR             X3, [X3,#0x1C0]                                        ; +0x84, 0xa6d60c\nBLR             X3                                                     ; +0x88, 0xa6d610\nLDR             X1, [X19]                                              ; +0x8c, 0xa6d614\nMOV             X0, X19                                                ; +0x90, 0xa6d618\nFMOV            S0, #2.0                                               ; +0x94, 0xa6d61c\nLDR             X1, [X1,#0xA0]                                         ; +0x98, 0xa6d620\nBLR             X1                                                     ; +0x9c, 0xa6d624\nMOV             X0, X19; this                                          ; +0xa0, 0xa6d628\nBL              _ZN7cocos2d16CCParticleSystem11resetSystemEv; cocos2d::CCParticleSystem::resetSystem(void) ; +0xa4, 0xa6d62c\nFMOV            S1, #0.5                                               ; +0xa8, 0xa6d630\nLDR             X1, [X19]                                              ; +0xac, 0xa6d634\nLDR             S0, [X29,#0x70+var_28]                                 ; +0xb0, 0xa6d638\nMOV             X0, X20; this                                          ; +0xb4, 0xa6d63c\nLDR             S2, [X29,#0x70+var_24]                                 ; +0xb8, 0xa6d640\nFMUL            S0, S0, S1; float                                      ; +0xbc, 0xa6d644\nLDR             X23, [X1,#0xB8]                                        ; +0xc0, 0xa6d648\nFMUL            S1, S2, S1; float                                      ; +0xc4, 0xa6d64c\nBL              _ZN7cocos2d7CCPointC1Eff; cocos2d::CCPoint::CCPoint(float,float) ; +0xc8, 0xa6d650\nMOV             X0, X19                                                ; +0xcc, 0xa6d654\nMOV             X1, X20                                                ; +0xd0, 0xa6d658\nBLR             X23                                                    ; +0xd4, 0xa6d65c\nLDR             X1, [X19]                                              ; +0xd8, 0xa6d660\nLDR             W0, [X22,#0x290]; int                                  ; +0xdc, 0xa6d664\nLDR             X23, [X1,#0x540]                                       ; +0xe0, 0xa6d668\nBL              _Z16darkColorForPathi; darkColorForPath(int)           ; +0xe4, 0xa6d66c\nMOV             X0, X19                                                ; +0xe8, 0xa6d670\nMOV             X1, X20                                                ; +0xec, 0xa6d674\nSTR             S0, [X29,#0x70+var_18]                                 ; +0xf0, 0xa6d678\nSTR             S1, [X29,#0x70+var_14]                                 ; +0xf4, 0xa6d67c\nSTR             S2, [X29,#0x70+var_10]                                 ; +0xf8, 0xa6d680\nSTR             S3, [X29,#0x70+var_C]                                  ; +0xfc, 0xa6d684\nBLR             X23                                                    ; +0x100, 0xa6d688\nLDR             X1, [X19]                                              ; +0x104, 0xa6d68c\nLDR             W0, [X22,#0x290]; int                                  ; +0x108, 0xa6d690\nLDR             X22, [X1,#0x560]                                       ; +0x10c, 0xa6d694\nBL              _Z17lightColorForPathi; lightColorForPath(int)         ; +0x110, 0xa6d698\nMOV             X0, X19                                                ; +0x114, 0xa6d69c\nMOV             X1, X20                                                ; +0x118, 0xa6d6a0\nSTR             S0, [X29,#0x70+var_18]                                 ; +0x11c, 0xa6d6a4\nSTR             S1, [X29,#0x70+var_14]                                 ; +0x120, 0xa6d6a8\nSTR             S2, [X29,#0x70+var_10]                                 ; +0x124, 0xa6d6ac\nSTR             S3, [X29,#0x70+var_C]                                  ; +0x128, 0xa6d6b0\nBLR             X22                                                    ; +0x12c, 0xa6d6b4\nADRP            X1, #off_122EFE8@PAGE                                  ; +0x130, 0xa6d6b8\nLDR             X2, [X29,#0x70+var_20]                                 ; +0x134, 0xa6d6bc\nSUB             X0, X2, #0x18; p                                       ; +0x138, 0xa6d6c0\nLDR             X1, [X1,#off_122EFE8@PAGEOFF]; qword_124B6B0           ; +0x13c, 0xa6d6c4\nCMP             X0, X1                                                 ; +0x140, 0xa6d6c8\nB.NE            loc_A6D6F8                                             ; +0x144, 0xa6d6cc\nLDR             X21, [X21,#__stack_chk_guard_ptr@PAGEOFF]; __stack_chk_guard ; +0x148, 0xa6d6d0\nLDR             X1, [X29,#0x70+var_8]                                  ; +0x14c, 0xa6d6d4\nLDR             X0, [X21]                                              ; +0x150, 0xa6d6d8\nCMP             X1, X0                                                 ; +0x154, 0xa6d6dc\nB.NE            loc_A6D73C                                             ; +0x158, 0xa6d6e0\nLDP             X19, X20, [SP,#0x70+var_60]                            ; +0x15c, 0xa6d6e4\nLDP             X21, X22, [SP,#0x70+var_50]                            ; +0x160, 0xa6d6e8\nLDR             X23, [SP,#0x70+var_40]                                 ; +0x164, 0xa6d6ec\nLDP             X29, X30, [SP+0x70+var_70],#0x70                       ; +0x168, 0xa6d6f0\nRET                                                                    ; +0x16c, 0xa6d6f4\nADRP            X1, #pthread_create_ptr_0@PAGE                         ; +0x170, 0xa6d6f8\nLDR             X1, [X1,#pthread_create_ptr_0@PAGEOFF]; pthread_create ; +0x174, 0xa6d6fc\nCBZ             X1, loc_A6D72C                                         ; +0x178, 0xa6d700\nSUB             X2, X2, #8                                             ; +0x17c, 0xa6d704\nLDAXR           W1, [X2]                                               ; +0x180, 0xa6d708\nSUB             W3, W1, #1                                             ; +0x184, 0xa6d70c\nSTLXR           W4, W3, [X2]                                           ; +0x188, 0xa6d710\nCBNZ            W4, loc_A6D708                                         ; +0x18c, 0xa6d714\nCMP             W1, WZR                                                ; +0x190, 0xa6d718\nB.GT            loc_A6D6D0                                             ; +0x194, 0xa6d71c\nMOV             X1, X20                                                ; +0x198, 0xa6d720\nBL              j__ZdlPv; operator delete(void *)                      ; +0x19c, 0xa6d724\nB               loc_A6D6D0                                             ; +0x1a0, 0xa6d728\nLDUR            W1, [X2,#-8]                                           ; +0x1a4, 0xa6d72c\nSUB             W3, W1, #1                                             ; +0x1a8, 0xa6d730\nSTUR            W3, [X2,#-8]                                           ; +0x1ac, 0xa6d734\nB               loc_A6D718                                             ; +0x1b0, 0xa6d738\nBL              .__stack_chk_fail                                      ; +0x1b4, 0xa6d73c\nADRP            X1, #off_122EFE8@PAGE                                  ; +0x1b8, 0xa6d740\nMOV             X19, X0                                                ; +0x1bc, 0xa6d744\nLDR             X0, [X29,#0x70+var_20]                                 ; +0x1c0, 0xa6d748\nLDR             X1, [X1,#off_122EFE8@PAGEOFF]; qword_124B6B0           ; +0x1c4, 0xa6d74c\nSUB             X0, X0, #0x18                                          ; +0x1c8, 0xa6d750\nCMP             X0, X1                                                 ; +0x1cc, 0xa6d754\nB.EQ            loc_A6D764                                             ; +0x1d0, 0xa6d758\nMOV             X1, X20                                                ; +0x1d4, 0xa6d75c\nBL              sub_4DDBA0                                             ; +0x1d8, 0xa6d760\nMOV             X0, X19                                                ; +0x1dc, 0xa6d764\nBL              _Unwind_Resume                                         ; +0x1e0, 0xa6d768", "xrefs": ["<???> @ 0x53fd0", "GJPathPage::playUnlockAnimation @ 0xa6e2a8", "<???> @ 0x122ab28"], "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"}