{"type": "func", "start": 4295391616, "end": 4295392228, "name": "ButtonSprite::init", "pseudocode": "// \n// ButtonSprite::init from 0x100067980 to 0x100067be4 (612 bytes)\n// \n// 1 xrefs:\n// > ButtonSprite::create @ 0x100067920\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 10:57:56 +0000\n// \n\n__int64 __fastcall ButtonSprite::init(\n        __int64 a1,\n        __int64 a2,\n        int a3,\n        int a4,\n        char a5,\n        __int64 a6,\n        char a7,\n        float a8,\n        float a9,\n        float a10)\n{\n  __int64 v20; // x20\n  __int64 v21; // x1\n  __int64 v22; // x21\n  __n128 v23; // q0\n  float v24; // s9\n  __int64 v25; // x21\n  float *v26; // x0\n  float v27; // s9\n  __int64 v28; // x21\n  __int64 v29; // x0\n  __int64 v30; // x21\n  float v32[4]; // [xsp+0h] [xbp-70h] BYREF\n\n  v20 = cocos2d::CCSprite::init(a1);\n  if ( (_DWORD)v20 )\n  {\n    *(_DWORD *)(a1 + 596) = 0;\n    *(float *)(a1 + 600) = (float)a3;\n    *(float *)(a1 + 604) = (float)a4;\n    *(float *)(a1 + 608) = a9;\n    *(_BYTE *)(a1 + 620) = a5;\n    *(float *)(a1 + 612) = a10;\n    *(_QWORD *)(a1 + 632) = a2;\n    (*(void (__fastcall **)(__int64, __int64, __int64))(*(_QWORD *)a1 + 464LL))(a1, a2, 1);\n    if ( (a7 & 1) != 0 )\n    {\n      v21 = cocos2d::CCSprite::create(a6);\n      *(_QWORD *)(a1 + 640) = v21;\n    }\n    else\n    {\n      sub_1000262CC(v32, 0.0, 0.0, 40.0, 40.0);\n      v22 = cocos2d::extension::CCScale9Sprite::create(a6, v32);\n      *(_QWORD *)(a1 + 648) = v22;\n      sub_1000262C4(v32, 16.0, 16.0);\n      (*(void (__fastcall **)(__int64, float *))(*(_QWORD *)v22 + 320LL))(v22, v32);\n      v21 = *(_QWORD *)(a1 + 648);\n    }\n    (*(void (__fastcall **)(__int64, __int64, _QWORD))(*(_QWORD *)a1 + 464LL))(a1, v21, 0);\n    v23.n128_u32[0] = *(_DWORD *)(a1 + 600);\n    if ( v23.n128_f32[0] > 0.0 )\n    {\n      v23.n128_u32[0] = *(_DWORD *)(*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 632) + 328LL))(*(_QWORD *)(a1 + 632));\n      v24 = *(float *)(a1 + 600);\n      if ( v23.n128_f32[0] > v24 )\n      {\n        v25 = *(_QWORD *)(a1 + 632);\n        v26 = (float *)(*(__int64 (__fastcall **)(__int64, float))(*(_QWORD *)v25 + 328LL))(v25, v23.n128_f32[0]);\n        (*(void (__fastcall **)(__int64, float))(*(_QWORD *)v25 + 160LL))(v25, v24 / *v26);\n      }\n    }\n    if ( a8 > 0.0\n      && *(float *)((*(__int64 (__fastcall **)(_QWORD, __n128))(**(_QWORD **)(a1 + 632) + 328LL))(\n                      *(_QWORD *)(a1 + 632),\n                      v23)\n                  + 4) > a8 )\n    {\n      v27 = a8\n          / *(float *)((*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 632) + 328LL))(*(_QWORD *)(a1 + 632)) + 4);\n      if ( v27 < (*(float (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 632) + 168LL))(*(_QWORD *)(a1 + 632)) )\n      {\n        v28 = *(_QWORD *)(a1 + 632);\n        v29 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v28 + 328LL))(v28);\n        (*(void (__fastcall **)(__int64, float))(*(_QWORD *)v28 + 160LL))(v28, a8 / *(float *)(v29 + 4));\n      }\n    }\n    v30 = *(_QWORD *)(a1 + 632);\n    if ( (*(float (__fastcall **)(__int64))(*(_QWORD *)v30 + 168LL))(v30) <= *(float *)(a1 + 608) )\n      (*(void (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 632) + 168LL))(*(_QWORD *)(a1 + 632));\n    (*(void (__fastcall **)(__int64))(*(_QWORD *)v30 + 160LL))(v30);\n    ButtonSprite::updateSpriteBGSize(a1);\n  }\n  return v20;\n}", "assembly": "; \n; ButtonSprite::init from 0x100067980 to 0x100067be4 (612 bytes)\n; \n; 1 xrefs:\n; > ButtonSprite::create @ 0x100067920\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 10:57:56 +0000\n; \nSUB             SP, SP, #0x80                                          ; +0x0, 0x100067980\nSTP             D11, D10, [SP,#0x70+var_60]                            ; +0x4, 0x100067984\nSTP             D9, D8, [SP,#0x70+var_50]                              ; +0x8, 0x100067988\nSTP             X26, X25, [SP,#0x70+var_40]                            ; +0xc, 0x10006798c\nSTP             X24, X23, [SP,#0x70+var_30]                            ; +0x10, 0x100067990\nSTP             X22, X21, [SP,#0x70+var_20]                            ; +0x14, 0x100067994\nSTP             X20, X19, [SP,#0x70+var_10]                            ; +0x18, 0x100067998\nSTP             X29, X30, [SP,#0x70+var_s0]                            ; +0x1c, 0x10006799c\nADD             X29, SP, #0x70                                         ; +0x20, 0x1000679a0\nFMOV            S9, S2                                                 ; +0x24, 0x1000679a4\nMOV             X22, X6                                                ; +0x28, 0x1000679a8\nMOV             X21, X5                                                ; +0x2c, 0x1000679ac\nMOV             X24, X4                                                ; +0x30, 0x1000679b0\nFMOV            S10, S1                                                ; +0x34, 0x1000679b4\nFMOV            S8, S0                                                 ; +0x38, 0x1000679b8\nMOV             X25, X3                                                ; +0x3c, 0x1000679bc\nMOV             X26, X2                                                ; +0x40, 0x1000679c0\nMOV             X23, X1                                                ; +0x44, 0x1000679c4\nMOV             X19, X0                                                ; +0x48, 0x1000679c8\nBL              cocos2d__CCSprite__init                                ; +0x4c, 0x1000679cc\nMOV             X20, X0                                                ; +0x50, 0x1000679d0\nCBZ             W0, loc_100067BBC                                      ; +0x54, 0x1000679d4\nSTR             WZR, [X19,#0x254]                                      ; +0x58, 0x1000679d8\nSCVTF           S0, W26                                                ; +0x5c, 0x1000679dc\nSTR             S0, [X19,#0x258]                                       ; +0x60, 0x1000679e0\nSCVTF           S0, W25                                                ; +0x64, 0x1000679e4\nSTR             S0, [X19,#0x25C]                                       ; +0x68, 0x1000679e8\nSTR             S10, [X19,#0x260]                                      ; +0x6c, 0x1000679ec\nSTRB            W24, [X19,#0x26C]                                      ; +0x70, 0x1000679f0\nSTR             S9, [X19,#0x264]                                       ; +0x74, 0x1000679f4\nSTR             X23, [X19,#0x278]                                      ; +0x78, 0x1000679f8\nLDR             X8, [X19]                                              ; +0x7c, 0x1000679fc\nLDR             X8, [X8,#0x1D0]                                        ; +0x80, 0x100067a00\nMOV             X0, X19                                                ; +0x84, 0x100067a04\nMOV             X1, X23                                                ; +0x88, 0x100067a08\nMOV             W2, #1                                                 ; +0x8c, 0x100067a0c\nBLR             X8                                                     ; +0x90, 0x100067a10\nTBZ             W22, #0, loc_100067A2C                                 ; +0x94, 0x100067a14\nMOV             X0, X21                                                ; +0x98, 0x100067a18\nBL              cocos2d__CCSprite__create                              ; +0x9c, 0x100067a1c\nMOV             X1, X0                                                 ; +0xa0, 0x100067a20\nSTR             X0, [X19,#0x280]                                       ; +0xa4, 0x100067a24\nB               loc_100067A84                                          ; +0xa8, 0x100067a28\nMOV             W8, #0x42200000                                        ; +0xac, 0x100067a2c\nFMOV            S2, W8                                                 ; +0xb0, 0x100067a30\nMOV             X0, SP                                                 ; +0xb4, 0x100067a34\nFMOV            S0, WZR                                                ; +0xb8, 0x100067a38\nFMOV            S1, WZR                                                ; +0xbc, 0x100067a3c\nFMOV            S3, S2                                                 ; +0xc0, 0x100067a40\nBL              sub_1000262CC                                          ; +0xc4, 0x100067a44\nMOV             X1, SP                                                 ; +0xc8, 0x100067a48\nMOV             X0, X21                                                ; +0xcc, 0x100067a4c\nBL              cocos2d__extension__CCScale9Sprite__create             ; +0xd0, 0x100067a50\nMOV             X21, X0                                                ; +0xd4, 0x100067a54\nSTR             X0, [X19,#0x288]                                       ; +0xd8, 0x100067a58\nMOV             X0, SP                                                 ; +0xdc, 0x100067a5c\nFMOV            S0, #16.0                                              ; +0xe0, 0x100067a60\nFMOV            S1, #16.0                                              ; +0xe4, 0x100067a64\nBL              sub_1000262C4                                          ; +0xe8, 0x100067a68\nLDR             X8, [X21]                                              ; +0xec, 0x100067a6c\nLDR             X8, [X8,#0x140]                                        ; +0xf0, 0x100067a70\nMOV             X1, SP                                                 ; +0xf4, 0x100067a74\nMOV             X0, X21                                                ; +0xf8, 0x100067a78\nBLR             X8                                                     ; +0xfc, 0x100067a7c\nLDR             X1, [X19,#0x288]                                       ; +0x100, 0x100067a80\nLDR             X8, [X19]                                              ; +0x104, 0x100067a84\nLDR             X8, [X8,#0x1D0]                                        ; +0x108, 0x100067a88\nMOV             X0, X19                                                ; +0x10c, 0x100067a8c\nMOV             W2, #0                                                 ; +0x110, 0x100067a90\nBLR             X8                                                     ; +0x114, 0x100067a94\nLDR             S0, [X19,#0x258]                                       ; +0x118, 0x100067a98\nFCMP            S0, #0.0                                               ; +0x11c, 0x100067a9c\nB.LE            loc_100067AF0                                          ; +0x120, 0x100067aa0\nLDR             X0, [X19,#0x278]                                       ; +0x124, 0x100067aa4\nLDR             X8, [X0]                                               ; +0x128, 0x100067aa8\nLDR             X8, [X8,#0x148]                                        ; +0x12c, 0x100067aac\nBLR             X8                                                     ; +0x130, 0x100067ab0\nLDR             S0, [X0]                                               ; +0x134, 0x100067ab4\nLDR             S9, [X19,#0x258]                                       ; +0x138, 0x100067ab8\nFCMP            S0, S9                                                 ; +0x13c, 0x100067abc\nB.LE            loc_100067AF0                                          ; +0x140, 0x100067ac0\nLDR             X21, [X19,#0x278]                                      ; +0x144, 0x100067ac4\nLDR             X8, [X21]                                              ; +0x148, 0x100067ac8\nLDR             X8, [X8,#0x148]                                        ; +0x14c, 0x100067acc\nMOV             X0, X21                                                ; +0x150, 0x100067ad0\nBLR             X8                                                     ; +0x154, 0x100067ad4\nLDR             S0, [X0]                                               ; +0x158, 0x100067ad8\nLDR             X8, [X21]                                              ; +0x15c, 0x100067adc\nLDR             X8, [X8,#0xA0]                                         ; +0x160, 0x100067ae0\nFDIV            S0, S9, S0                                             ; +0x164, 0x100067ae4\nMOV             X0, X21                                                ; +0x168, 0x100067ae8\nBLR             X8                                                     ; +0x16c, 0x100067aec\nFCMP            S8, #0.0                                               ; +0x170, 0x100067af0\nB.LE            loc_100067B70                                          ; +0x174, 0x100067af4\nLDR             X0, [X19,#0x278]                                       ; +0x178, 0x100067af8\nLDR             X8, [X0]                                               ; +0x17c, 0x100067afc\nLDR             X8, [X8,#0x148]                                        ; +0x180, 0x100067b00\nBLR             X8                                                     ; +0x184, 0x100067b04\nLDR             S0, [X0,#4]                                            ; +0x188, 0x100067b08\nFCMP            S0, S8                                                 ; +0x18c, 0x100067b0c\nB.LE            loc_100067B70                                          ; +0x190, 0x100067b10\nLDR             X0, [X19,#0x278]                                       ; +0x194, 0x100067b14\nLDR             X8, [X0]                                               ; +0x198, 0x100067b18\nLDR             X8, [X8,#0x148]                                        ; +0x19c, 0x100067b1c\nBLR             X8                                                     ; +0x1a0, 0x100067b20\nLDR             S0, [X0,#4]                                            ; +0x1a4, 0x100067b24\nFDIV            S9, S8, S0                                             ; +0x1a8, 0x100067b28\nLDR             X0, [X19,#0x278]                                       ; +0x1ac, 0x100067b2c\nLDR             X8, [X0]                                               ; +0x1b0, 0x100067b30\nLDR             X8, [X8,#0xA8]                                         ; +0x1b4, 0x100067b34\nBLR             X8                                                     ; +0x1b8, 0x100067b38\nFCMP            S9, S0                                                 ; +0x1bc, 0x100067b3c\nB.PL            loc_100067B70                                          ; +0x1c0, 0x100067b40\nLDR             X21, [X19,#0x278]                                      ; +0x1c4, 0x100067b44\nLDR             X8, [X21]                                              ; +0x1c8, 0x100067b48\nLDR             X8, [X8,#0x148]                                        ; +0x1cc, 0x100067b4c\nMOV             X0, X21                                                ; +0x1d0, 0x100067b50\nBLR             X8                                                     ; +0x1d4, 0x100067b54\nLDR             S0, [X0,#4]                                            ; +0x1d8, 0x100067b58\nLDR             X8, [X21]                                              ; +0x1dc, 0x100067b5c\nLDR             X8, [X8,#0xA0]                                         ; +0x1e0, 0x100067b60\nFDIV            S0, S8, S0                                             ; +0x1e4, 0x100067b64\nMOV             X0, X21                                                ; +0x1e8, 0x100067b68\nBLR             X8                                                     ; +0x1ec, 0x100067b6c\nLDR             X21, [X19,#0x278]                                      ; +0x1f0, 0x100067b70\nLDR             X8, [X21]                                              ; +0x1f4, 0x100067b74\nLDR             X8, [X8,#0xA8]                                         ; +0x1f8, 0x100067b78\nMOV             X0, X21                                                ; +0x1fc, 0x100067b7c\nBLR             X8                                                     ; +0x200, 0x100067b80\nFMOV            S1, S0                                                 ; +0x204, 0x100067b84\nLDR             S0, [X19,#0x260]                                       ; +0x208, 0x100067b88\nFCMP            S1, S0                                                 ; +0x20c, 0x100067b8c\nB.GT            loc_100067BA4                                          ; +0x210, 0x100067b90\nLDR             X0, [X19,#0x278]                                       ; +0x214, 0x100067b94\nLDR             X8, [X0]                                               ; +0x218, 0x100067b98\nLDR             X8, [X8,#0xA8]                                         ; +0x21c, 0x100067b9c\nBLR             X8                                                     ; +0x220, 0x100067ba0\nLDR             X8, [X21]                                              ; +0x224, 0x100067ba4\nLDR             X8, [X8,#0xA0]                                         ; +0x228, 0x100067ba8\nMOV             X0, X21                                                ; +0x22c, 0x100067bac\nBLR             X8                                                     ; +0x230, 0x100067bb0\nMOV             X0, X19                                                ; +0x234, 0x100067bb4\nBL              ButtonSprite__updateSpriteBGSize                       ; +0x238, 0x100067bb8\nMOV             X0, X20                                                ; +0x23c, 0x100067bbc\nLDP             X29, X30, [SP,#0x70+var_s0]                            ; +0x240, 0x100067bc0\nLDP             X20, X19, [SP,#0x70+var_10]                            ; +0x244, 0x100067bc4\nLDP             X22, X21, [SP,#0x70+var_20]                            ; +0x248, 0x100067bc8\nLDP             X24, X23, [SP,#0x70+var_30]                            ; +0x24c, 0x100067bcc\nLDP             X26, X25, [SP,#0x70+var_40]                            ; +0x250, 0x100067bd0\nLDP             D9, D8, [SP,#0x70+var_50]                              ; +0x254, 0x100067bd4\nLDP             D11, D10, [SP,#0x70+var_60]                            ; +0x258, 0x100067bd8\nADD             SP, SP, #0x80                                          ; +0x25c, 0x100067bdc\nRET                                                                    ; +0x260, 0x100067be0", "xrefs": ["ButtonSprite::create @ 0x100067920"], "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"}