{"type": "func", "start": 11519496, "end": 11520028, "name": "CreateParticlePopup::update", "pseudocode": "// \n// CreateParticlePopup::update from 0xafc608 to 0xafc81c (532 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0x5f500\n// > <???> @ 0x14afe08\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 13:01:18 +0000\n// \n\nvoid __fastcall CreateParticlePopup::update(CreateParticlePopup *this, float a2)\n{\n  float v4; // s0\n  float v5; // s9\n  float v6; // s1\n  float *v7; // x0\n  float v8; // s8\n  cocos2d::CCParticleSystem *v9; // x0\n  float v10; // s3\n  unsigned __int64 v11; // x1\n  float v12; // s2\n  __int64 v13; // x20\n  __int64 v14; // x0\n  void (__fastcall *v15)(__int64, __int64); // x21\n  float v16; // s0\n  cocos2d::CCString *v17; // x0\n  __int64 CString; // x0\n  char *v19; // [xsp+40h] [xbp+40h]\n  __int64 v20; // [xsp+48h] [xbp+48h]\n\n  if ( *((_BYTE *)this + 976) )\n  {\n    v4 = a2 + *((float *)this + 245);\n    if ( v4 >= 0.1 )\n    {\n      v13 = *((_QWORD *)this + 123);\n      v14 = *((_QWORD *)this + 89);\n      *((_DWORD *)this + 245) = 0;\n      v15 = *(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v13 + 928LL);\n      v19 = (char *)(*(unsigned int (__fastcall **)(__int64))(*(_QWORD *)v14 + 912LL))(v14);\n      v20 = (*(unsigned int (__fastcall **)(_QWORD))(**((_QWORD **)this + 89) + 1496LL))(*((_QWORD *)this + 89));\n      cocos2d::CCParticleSystem::getParticleDrawCost(*((cocos2d::CCParticleSystem **)this + 89));\n      v17 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(\n                                   (cocos2d::CCString *)\"%i/%i\\n%.0f\",\n                                   v19,\n                                   v20,\n                                   (float)(v16 / 10.0));\n      CString = cocos2d::CCString::getCString(v17);\n      v15(v13, CString);\n    }\n    else\n    {\n      *((float *)this + 245) = v4;\n    }\n  }\n  v5 = (*(float (__fastcall **)(_QWORD))(**((_QWORD **)this + 89) + 920LL))(*((_QWORD *)this + 89));\n  if ( v5 >= 0.0 )\n  {\n    v6 = *((float *)this + 251);\n    *((float *)this + 206) = *((float *)this + 206) + a2;\n    if ( v6 < 0.0 )\n    {\n      v7 = *((float **)this + 89);\n      v10 = v7[134];\n      v11 = 214013 * qword_155E040 + 2531011;\n      qword_155E040 = v11;\n      v12 = v7[135];\n      if ( (float)(v10 + (float)((float)((float)((float)((float)((v11 >> 16) & 0x7FFF) / 32767.0) * 2.0) + -1.0) * v12)) <= 0.0 )\n      {\n        *((_DWORD *)this + 251) = 0;\n      }\n      else\n      {\n        qword_155E040 = 214013 * v11 + 2531011;\n        *((float *)this + 251) = v10\n                               + (float)(v12\n                                       * (float)((float)((float)((float)(((unsigned __int64)qword_155E040 >> 16) & 0x7FFF)\n                                                               / 32767.0)\n                                                       * 2.0)\n                                               + -1.0));\n      }\n    }\n    else\n    {\n      v7 = *((float **)this + 89);\n    }\n    v8 = (*(float (__fastcall **)(float *))(*(_QWORD *)v7 + 968LL))(v7);\n    if ( *((float *)this + 206) > (float)(v5\n                                        + (float)((float)(v8\n                                                        + (*(float (__fastcall **)(_QWORD))(**((_QWORD **)this + 89)\n                                                                                          + 984LL))(*((_QWORD *)this + 89)))\n                                                + *((float *)this + 251))) )\n    {\n      v9 = *((cocos2d::CCParticleSystem **)this + 89);\n      *((float *)this + 251) = -1.0;\n      *((_DWORD *)this + 206) = 0;\n      cocos2d::CCParticleSystem::resetSystem(v9);\n    }\n  }\n}", "assembly": "; \n; CreateParticlePopup::update from 0xafc608 to 0xafc81c (532 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0x5f500\n; > <???> @ 0x14afe08\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 13:01:18 +0000\n; \nSTP             X29, X30, [SP,#var_50]!                                ; +0x0, 0xafc608\nMOV             X29, SP                                                ; +0x4, 0xafc60c\nSTP             D8, D9, [SP,#0x50+var_28]                              ; +0x8, 0xafc610\nSTP             X19, X20, [SP,#0x50+var_40]                            ; +0xc, 0xafc614\nSTR             X21, [SP,#0x50+var_30]                                 ; +0x10, 0xafc618\nMOV             X19, X0                                                ; +0x14, 0xafc61c\nFMOV            S8, S0                                                 ; +0x18, 0xafc620\nLDRB            W0, [X0,#0x3D0]                                        ; +0x1c, 0xafc624\nCBZ             W0, loc_AFC648                                         ; +0x20, 0xafc628\nLDR             S0, [X19,#0x3D4]                                       ; +0x24, 0xafc62c\nLDR             D1, =0x3FB999999999999A                                ; +0x28, 0xafc630\nFADD            S0, S8, S0                                             ; +0x2c, 0xafc634\nFCVT            D2, S0                                                 ; +0x30, 0xafc638\nFCMPE           D2, D1                                                 ; +0x34, 0xafc63c\nB.GE            loc_AFC788                                             ; +0x38, 0xafc640\nSTR             S0, [X19,#0x3D4]                                       ; +0x3c, 0xafc644\nLDR             X1, [X19,#0x2C8]                                       ; +0x40, 0xafc648\nMOV             X0, X1                                                 ; +0x44, 0xafc64c\nLDR             X1, [X1]                                               ; +0x48, 0xafc650\nLDR             X1, [X1,#0x398]                                        ; +0x4c, 0xafc654\nBLR             X1                                                     ; +0x50, 0xafc658\nFCMPE           S0, #0.0                                               ; +0x54, 0xafc65c\nFMOV            S9, S0                                                 ; +0x58, 0xafc660\nB.MI            loc_AFC6C4                                             ; +0x5c, 0xafc664\nLDR             S0, [X19,#0x338]                                       ; +0x60, 0xafc668\nLDR             S1, [X19,#0x3EC]                                       ; +0x64, 0xafc66c\nFADD            S0, S0, S8                                             ; +0x68, 0xafc670\nFCMPE           S1, #0.0                                               ; +0x6c, 0xafc674\nSTR             S0, [X19,#0x338]                                       ; +0x70, 0xafc678\nB.MI            loc_AFC700                                             ; +0x74, 0xafc67c\nLDR             X0, [X19,#0x2C8]                                       ; +0x78, 0xafc680\nLDR             X1, [X0]                                               ; +0x7c, 0xafc684\nLDR             X1, [X1,#0x3C8]                                        ; +0x80, 0xafc688\nBLR             X1                                                     ; +0x84, 0xafc68c\nLDR             X1, [X19,#0x2C8]                                       ; +0x88, 0xafc690\nFMOV            S8, S0                                                 ; +0x8c, 0xafc694\nMOV             X0, X1                                                 ; +0x90, 0xafc698\nLDR             X1, [X1]                                               ; +0x94, 0xafc69c\nLDR             X1, [X1,#0x3D8]                                        ; +0x98, 0xafc6a0\nBLR             X1                                                     ; +0x9c, 0xafc6a4\nFADD            S0, S8, S0                                             ; +0xa0, 0xafc6a8\nLDR             S1, [X19,#0x3EC]                                       ; +0xa4, 0xafc6ac\nLDR             S2, [X19,#0x338]                                       ; +0xa8, 0xafc6b0\nFADD            S8, S0, S1                                             ; +0xac, 0xafc6b4\nFADD            S8, S9, S8                                             ; +0xb0, 0xafc6b8\nFCMPE           S2, S8                                                 ; +0xb4, 0xafc6bc\nB.GT            loc_AFC6D8                                             ; +0xb8, 0xafc6c0\nLDP             X19, X20, [SP,#0x50+var_40]                            ; +0xbc, 0xafc6c4\nLDP             D8, D9, [SP,#0x50+var_28]                              ; +0xc0, 0xafc6c8\nLDR             X21, [SP,#0x50+var_30]                                 ; +0xc4, 0xafc6cc\nLDP             X29, X30, [SP+0x50+var_50],#0x50                       ; +0xc8, 0xafc6d0\nRET                                                                    ; +0xcc, 0xafc6d4\nFMOV            S0, #-1.0                                              ; +0xd0, 0xafc6d8\nLDR             X0, [X19,#0x2C8]; this                                 ; +0xd4, 0xafc6dc\nSTR             S0, [X19,#0x3EC]                                       ; +0xd8, 0xafc6e0\nFMOV            S0, WZR                                                ; +0xdc, 0xafc6e4\nSTR             S0, [X19,#0x338]                                       ; +0xe0, 0xafc6e8\nLDP             D8, D9, [SP,#0x50+var_28]                              ; +0xe4, 0xafc6ec\nLDP             X19, X20, [SP,#0x50+var_40]                            ; +0xe8, 0xafc6f0\nLDR             X21, [SP,#0x50+var_30]                                 ; +0xec, 0xafc6f4\nLDP             X29, X30, [SP+0x50+var_50],#0x50                       ; +0xf0, 0xafc6f8\nB               _ZN7cocos2d16CCParticleSystem11resetSystemEv; cocos2d::CCParticleSystem::resetSystem(void) ; +0xf4, 0xafc6fc\nADRP            X3, #qword_155E040@PAGE                                ; +0xf8, 0xafc700\nMOV             X2, #0x343FD                                           ; +0xfc, 0xafc704\nLDR             X0, [X19,#0x2C8]                                       ; +0x104, 0xafc70c\nLDR             S5, =0x46FFFE00                                        ; +0x108, 0xafc710\nLDR             X1, [X3,#qword_155E040@PAGEOFF]                        ; +0x10c, 0xafc714\nFMOV            S4, #2.0                                               ; +0x110, 0xafc718\nFMOV            S0, #-1.0                                              ; +0x114, 0xafc71c\nMUL             X1, X1, X2                                             ; +0x118, 0xafc720\nLDR             S3, [X0,#0x218]                                        ; +0x11c, 0xafc724\nADD             X1, X1, #0x269,LSL#12                                  ; +0x120, 0xafc728\nADD             X1, X1, #0xEC3                                         ; +0x124, 0xafc72c\nSTR             X1, [X3,#qword_155E040@PAGEOFF]                        ; +0x128, 0xafc730\nUBFX            X2, X1, #0x10, #0xF                                    ; +0x12c, 0xafc734\nLDR             S2, [X0,#0x21C]                                        ; +0x130, 0xafc738\nSCVTF           S1, X2                                                 ; +0x134, 0xafc73c\nFDIV            S1, S1, S5                                             ; +0x138, 0xafc740\nFMADD           S1, S1, S4, S0                                         ; +0x13c, 0xafc744\nFMADD           S1, S1, S2, S3                                         ; +0x140, 0xafc748\nFCMPE           S1, #0.0                                               ; +0x144, 0xafc74c\nB.LE            loc_AFC810                                             ; +0x148, 0xafc750\nMOV             X2, #0x343FD                                           ; +0x14c, 0xafc754\nMUL             X1, X1, X2                                             ; +0x154, 0xafc75c\nADD             X1, X1, #0x269,LSL#12                                  ; +0x158, 0xafc760\nADD             X1, X1, #0xEC3                                         ; +0x15c, 0xafc764\nSTR             X1, [X3,#qword_155E040@PAGEOFF]                        ; +0x160, 0xafc768\nUBFX            X1, X1, #0x10, #0xF                                    ; +0x164, 0xafc76c\nSCVTF           S1, X1                                                 ; +0x168, 0xafc770\nFDIV            S1, S1, S5                                             ; +0x16c, 0xafc774\nFMADD           S0, S1, S4, S0                                         ; +0x170, 0xafc778\nFMADD           S0, S2, S0, S3                                         ; +0x174, 0xafc77c\nSTR             S0, [X19,#0x3EC]                                       ; +0x178, 0xafc780\nB               loc_AFC684                                             ; +0x17c, 0xafc784\nFMOV            S0, WZR                                                ; +0x180, 0xafc788\nLDR             X1, [X19,#0x2C8]                                       ; +0x184, 0xafc78c\nLDR             X20, [X19,#0x3D8]                                      ; +0x188, 0xafc790\nMOV             X0, X1                                                 ; +0x18c, 0xafc794\nSTR             S0, [X19,#0x3D4]                                       ; +0x190, 0xafc798\nLDR             X1, [X1]                                               ; +0x194, 0xafc79c\nLDR             X2, [X20]                                              ; +0x198, 0xafc7a0\nLDR             X1, [X1,#0x390]                                        ; +0x19c, 0xafc7a4\nLDR             X21, [X2,#0x3A0]                                       ; +0x1a0, 0xafc7a8\nBLR             X1                                                     ; +0x1a4, 0xafc7ac\nMOV             W1, W0                                                 ; +0x1a8, 0xafc7b0\nLDR             X2, [X19,#0x2C8]                                       ; +0x1ac, 0xafc7b4\nSTR             X1, [X29,#0x50+var_10]                                 ; +0x1b0, 0xafc7b8\nMOV             X0, X2                                                 ; +0x1b4, 0xafc7bc\nLDR             X2, [X2]                                               ; +0x1b8, 0xafc7c0\nLDR             X2, [X2,#0x5D8]                                        ; +0x1bc, 0xafc7c4\nBLR             X2                                                     ; +0x1c0, 0xafc7c8\nMOV             W2, W0                                                 ; +0x1c4, 0xafc7cc\nLDR             X0, [X19,#0x2C8]; this                                 ; +0x1c8, 0xafc7d0\nSTR             X2, [X29,#0x50+var_8]                                  ; +0x1cc, 0xafc7d4\nBL              _ZN7cocos2d16CCParticleSystem19getParticleDrawCostEv; cocos2d::CCParticleSystem::getParticleDrawCost(void) ; +0x1d0, 0xafc7d8\nFMOV            S1, #10.0                                              ; +0x1d4, 0xafc7dc\nLDR             X1, [X29,#0x50+var_10]; char *                         ; +0x1d8, 0xafc7e0\nLDR             X2, [X29,#0x50+var_8]                                  ; +0x1dc, 0xafc7e4\nADRP            X0, #aII0f@PAGE; \"%i/%i\\n%.0f\"                         ; +0x1e0, 0xafc7e8\nFDIV            S0, S0, S1                                             ; +0x1e4, 0xafc7ec\nADD             X0, X0, #aII0f@PAGEOFF; \"%i/%i\\n%.0f\"                  ; +0x1e8, 0xafc7f0\nFCVT            D0, S0                                                 ; +0x1ec, 0xafc7f4\nBL              _ZN7cocos2d8CCString16createWithFormatEPKcz; cocos2d::CCString::createWithFormat(char const*,...) ; +0x1f0, 0xafc7f8\nBL              _ZNK7cocos2d8CCString10getCStringEv; cocos2d::CCString::getCString(void) ; +0x1f4, 0xafc7fc\nMOV             X1, X0                                                 ; +0x1f8, 0xafc800\nMOV             X0, X20                                                ; +0x1fc, 0xafc804\nBLR             X21                                                    ; +0x200, 0xafc808\nB               loc_AFC648                                             ; +0x204, 0xafc80c\nFMOV            S0, WZR                                                ; +0x208, 0xafc810\nSTR             S0, [X19,#0x3EC]                                       ; +0x20c, 0xafc814\nB               loc_AFC684                                             ; +0x210, 0xafc818", "xrefs": ["<???> @ 0x5f500", "<???> @ 0x14afe08"], "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"}