{"type": "func", "start": 5371300048, "end": 5371300621, "name": "GJGarageLayer::updateRate", "pseudocode": "// \n// GJGarageLayer::updateRate from 0x1402788d0 to 0x140278b0d (573 bytes)\n// \n// 3 xrefs:\n// > <???> @ 0x14056ad28\n// > <???> @ 0x1406d1004\n// > <???> @ 0x1406d1010\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\n// Hidden C++ exception states: #wind=4\nvoid GJGarageLayer::updateRate(GJGarageLayer *a1)\n{\n  __int64 v1; // rdx\n  __int64 v3; // rax\n  cocos2d::CCString *v4; // rax\n  const char *CString; // rsi\n  cocos2d::CCString *v6; // rax\n  const char *v7; // rdi\n  __int64 v8; // rdx\n  __int64 *v9; // rcx\n  __int64 v10; // rbx\n  cocos2d::CCSpriteFrameCache *v11; // rax\n  struct cocos2d::CCSpriteFrame *v12; // rax\n  struct cocos2d::CCSprite *v13; // rdi\n  float v14; // xmm0_4\n  cocos2d::CCSprite_vtbl *v15; // rbx\n  const cocos2d::CCPoint *v16; // rax\n  __int64 v17; // rcx\n  __int64 v18; // rax\n  void *v19; // [rsp+48h] [rbp+10h] BYREF\n  void *v20; // [rsp+50h] [rbp+18h]\n\n  v3 = qword_1406C2ED8;\n  if ( !qword_1406C2ED8 )\n  {\n    v19 = operator new(0x668u);\n    qword_1406C2ED8 = sub_14017AB00((__int64)v19);\n    (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);\n    v3 = qword_1406C2ED8;\n  }\n  if ( *(_BYTE *)(v3 + 676) && *(_QWORD *)&a1->m_obPosition.y )\n  {\n    v4 = cocos2d::CCString::createWithFormat(\"player_%02d_001.png\", 13);\n    CString = cocos2d::CCString::getCString(v4);\n    v6 = cocos2d::CCString::createWithFormat(\"player_%02d_2_001.png\", 13);\n    v7 = cocos2d::CCString::getCString(v6);\n    LOBYTE(v8) = 1;\n    (*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)&a1->m_obPosition.y + 560LL))(\n      *(_QWORD *)&a1->m_obPosition.y,\n      v8);\n    v9 = *(__int64 **)&a1->m_obPosition.y;\n    v10 = *v9;\n    v11 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v9);\n    v12 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v11, CString);\n    (*(void (__fastcall **)(_QWORD, struct cocos2d::CCSpriteFrame *))(v10 + 992))(*(_QWORD *)&a1->m_obPosition.y, v12);\n    v13 = cocos2d::CCSprite::createWithSpriteFrameName(v7);\n    v14 = (*(float (__fastcall **)(_QWORD, struct cocos2d::CCSprite *, __int64))(**(_QWORD **)&a1->m_obPosition.y + 440LL))(\n            *(_QWORD *)&a1->m_obPosition.y,\n            v13,\n            0xFFFFFFFFLL);\n    v15 = v13->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;\n    cocos2d::CCPoint::CCPoint(v14, *(float *)(*(_QWORD *)&a1->m_obPosition.y + 432LL) * 0.5);\n    v15->setPosition_0(v13, v16);\n    LOWORD(v19) = -20561;\n    BYTE2(v19) = -81;\n    (**(void (__fastcall ***)(__int64, void **))(*(_QWORD *)&a1->m_obPosition.y + 320LL))(\n      *(_QWORD *)&a1->m_obPosition.y + 320LL,\n      &v19);\n    LOWORD(v19) = -1;\n    BYTE2(v19) = -1;\n    v13->setColor(&v13->cocos2d::CCRGBAProtocol, (const cocos2d::ccColor3B *)&v19);\n    v3 = qword_1406C2ED8;\n    if ( !qword_1406C2ED8 )\n    {\n      v20 = operator new(0x668u);\n      qword_1406C2ED8 = sub_14017AB00((__int64)v20);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);\n      v3 = qword_1406C2ED8;\n    }\n    *(_QWORD *)(v3 + 928) = 0;\n  }\n  if ( *(_BYTE *)(v3 + 677) )\n  {\n    v17 = *(_QWORD *)&a1->m_fVertexZ;\n    if ( v17 )\n    {\n      LOBYTE(v1) = 1;\n      (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v17 + 560LL))(v17, v1);\n      v18 = qword_1406C2ED8;\n      if ( !qword_1406C2ED8 )\n      {\n        v19 = operator new(0x668u);\n        qword_1406C2ED8 = sub_14017AB00((__int64)v19);\n        (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);\n        v18 = qword_1406C2ED8;\n      }\n      *(_QWORD *)(v18 + 928) = 0;\n    }\n  }\n}", "assembly": "; \n; GJGarageLayer::updateRate from 0x1402788d0 to 0x140278b0d (573 bytes)\n; \n; 3 xrefs:\n; > <???> @ 0x14056ad28\n; > <???> @ 0x1406d1004\n; > <???> @ 0x1406d1010\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\nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x1402788d0\npush    rbp                                                            ; +0x5, 0x1402788d5\npush    rsi                                                            ; +0x6, 0x1402788d6\npush    rdi                                                            ; +0x7, 0x1402788d7\nsub     rsp, 20h                                                       ; +0x8, 0x1402788d8\nmov     rbp, rcx                                                       ; +0xc, 0x1402788dc\nmov     rax, cs:qword_1406C2ED8                                        ; +0xf, 0x1402788df\ntest    rax, rax                                                       ; +0x16, 0x1402788e6\njnz     short loc_14027891A                                            ; +0x19, 0x1402788e9\nmov     ecx, 668h; Size                                                ; +0x1b, 0x1402788eb\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x20, 0x1402788f0\nmov     [rsp+38h+arg_8], rax                                           ; +0x25, 0x1402788f5\nmov     rcx, rax                                                       ; +0x2a, 0x1402788fa\ncall    sub_14017AB00                                                  ; +0x2d, 0x1402788fd\nnop                                                                    ; +0x32, 0x140278902\nmov     cs:qword_1406C2ED8, rax                                        ; +0x33, 0x140278903\nmov     rdx, [rax]                                                     ; +0x3a, 0x14027890a\nmov     rcx, rax                                                       ; +0x3d, 0x14027890d\ncall    qword ptr [rdx+48h]                                            ; +0x40, 0x140278910\nmov     rax, cs:qword_1406C2ED8                                        ; +0x43, 0x140278913\ncmp     byte ptr [rax+2A4h], 0                                         ; +0x4a, 0x14027891a\njz      loc_140278A9D                                                  ; +0x51, 0x140278921\ncmp     qword ptr [rbp+50h], 0                                         ; +0x57, 0x140278927\njz      loc_140278A9D                                                  ; +0x5c, 0x14027892c\nmov     edx, 0Dh                                                       ; +0x62, 0x140278932\nlea     rcx, aPlayer02d001Pn; \"player_%02d_001.png\"                    ; +0x67, 0x140278937\ncall    cs:?createWithFormat@CCString@cocos2d@@SAPEAV12@PEBDZZ; cocos2d::CCString::createWithFormat(char const *,...) ; +0x6e, 0x14027893e\nmov     rcx, rax                                                       ; +0x74, 0x140278944\ncall    cs:?getCString@CCString@cocos2d@@QEBAPEBDXZ; cocos2d::CCString::getCString(void) ; +0x77, 0x140278947\nmov     rsi, rax                                                       ; +0x7d, 0x14027894d\nmov     edx, 0Dh                                                       ; +0x80, 0x140278950\nlea     rcx, aPlayer02d2001P; \"player_%02d_2_001.png\"                  ; +0x85, 0x140278955\ncall    cs:?createWithFormat@CCString@cocos2d@@SAPEAV12@PEBDZZ; cocos2d::CCString::createWithFormat(char const *,...) ; +0x8c, 0x14027895c\nmov     rcx, rax                                                       ; +0x92, 0x140278962\ncall    cs:?getCString@CCString@cocos2d@@QEBAPEBDXZ; cocos2d::CCString::getCString(void) ; +0x95, 0x140278965\nmov     rdi, rax                                                       ; +0x9b, 0x14027896b\nmov     rcx, [rbp+50h]                                                 ; +0x9e, 0x14027896e\nmov     r8, [rcx]                                                      ; +0xa2, 0x140278972\nmov     dl, 1                                                          ; +0xa5, 0x140278975\ncall    qword ptr [r8+230h]                                            ; +0xa7, 0x140278977\nmov     rcx, [rbp+50h]                                                 ; +0xae, 0x14027897e\nmov     rbx, [rcx]                                                     ; +0xb2, 0x140278982\ncall    cs:?sharedSpriteFrameCache@CCSpriteFrameCache@cocos2d@@SAPEAV12@XZ; cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(void) ; +0xb5, 0x140278985\nmov     rcx, rax                                                       ; +0xbb, 0x14027898b\nmov     rdx, rsi                                                       ; +0xbe, 0x14027898e\ncall    cs:?spriteFrameByName@CCSpriteFrameCache@cocos2d@@QEAAPEAVCCSpriteFrame@2@PEBD@Z; cocos2d::CCSpriteFrameCache::spriteFrameByName(char const *) ; +0xc1, 0x140278991\nmov     rdx, rax                                                       ; +0xc7, 0x140278997\nmov     rcx, [rbp+50h]                                                 ; +0xca, 0x14027899a\ncall    qword ptr [rbx+3E0h]                                           ; +0xce, 0x14027899e\nmov     rcx, rdi                                                       ; +0xd4, 0x1402789a4\ncall    cs:?createWithSpriteFrameName@CCSprite@cocos2d@@SAPEAV12@PEBD@Z; cocos2d::CCSprite::createWithSpriteFrameName(char const *) ; +0xd7, 0x1402789a7\nmov     rdi, rax                                                       ; +0xdd, 0x1402789ad\nmov     rcx, [rbp+50h]                                                 ; +0xe0, 0x1402789b0\nmov     r9, [rcx]                                                      ; +0xe4, 0x1402789b4\nmov     r8d, 0FFFFFFFFh                                                ; +0xe7, 0x1402789b7\nmov     rdx, rax                                                       ; +0xed, 0x1402789bd\ncall    qword ptr [r9+1B8h]                                            ; +0xf0, 0x1402789c0\nmov     rcx, [rbp+50h]                                                 ; +0xf7, 0x1402789c7\nmov     rbx, [rdi]                                                     ; +0xfb, 0x1402789cb\nmovss   xmm2, dword ptr [rcx+1B4h]                                     ; +0xfe, 0x1402789ce\nmulss   xmm2, cs:dword_140622B08                                       ; +0x106, 0x1402789d6\nmovss   xmm1, dword ptr [rcx+1B0h]                                     ; +0x10e, 0x1402789de\nmulss   xmm1, cs:dword_140622B08                                       ; +0x116, 0x1402789e6\nlea     rcx, [rsp+38h+arg_8]                                           ; +0x11e, 0x1402789ee\ncall    cs:??0CCPoint@cocos2d@@QEAA@MM@Z; cocos2d::CCPoint::CCPoint(float,float) ; +0x123, 0x1402789f3\nmov     rdx, rax                                                       ; +0x129, 0x1402789f9\nmov     rcx, rdi                                                       ; +0x12c, 0x1402789fc\ncall    qword ptr [rbx+0B8h]                                           ; +0x12f, 0x1402789ff\nmov     word ptr [rsp+38h+arg_8], 0AFAFh                               ; +0x135, 0x140278a05\nmovzx   eax, word ptr [rsp+38h+arg_8]                                  ; +0x13c, 0x140278a0c\nmov     word ptr [rsp+38h+arg_8], ax                                   ; +0x141, 0x140278a11\nmov     byte ptr [rsp+38h+arg_8+2], 0AFh                               ; +0x146, 0x140278a16\nmov     rcx, [rbp+50h]                                                 ; +0x14b, 0x140278a1b\nadd     rcx, 140h                                                      ; +0x14f, 0x140278a1f\nmov     rax, [rcx]                                                     ; +0x156, 0x140278a26\nlea     rdx, [rsp+38h+arg_8]                                           ; +0x159, 0x140278a29\ncall    qword ptr [rax]                                                ; +0x15e, 0x140278a2e\nmov     word ptr [rsp+38h+arg_8], 0FFFFh                               ; +0x160, 0x140278a30\nmovzx   eax, word ptr [rsp+38h+arg_8]                                  ; +0x167, 0x140278a37\nmov     word ptr [rsp+38h+arg_8], ax                                   ; +0x16c, 0x140278a3c\nmov     byte ptr [rsp+38h+arg_8+2], 0FFh                               ; +0x171, 0x140278a41\nlea     rcx, [rdi+140h]                                                ; +0x176, 0x140278a46\nmov     rax, [rcx]                                                     ; +0x17d, 0x140278a4d\nlea     rdx, [rsp+38h+arg_8]                                           ; +0x180, 0x140278a50\ncall    qword ptr [rax]                                                ; +0x185, 0x140278a55\nmov     rax, cs:qword_1406C2ED8                                        ; +0x187, 0x140278a57\ntest    rax, rax                                                       ; +0x18e, 0x140278a5e\njnz     short loc_140278A92                                            ; +0x191, 0x140278a61\nmov     ecx, 668h; Size                                                ; +0x193, 0x140278a63\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x198, 0x140278a68\nmov     [rsp+38h+arg_10], rax                                          ; +0x19d, 0x140278a6d\nmov     rcx, rax                                                       ; +0x1a2, 0x140278a72\ncall    sub_14017AB00                                                  ; +0x1a5, 0x140278a75\nnop                                                                    ; +0x1aa, 0x140278a7a\nmov     cs:qword_1406C2ED8, rax                                        ; +0x1ab, 0x140278a7b\nmov     rdx, [rax]                                                     ; +0x1b2, 0x140278a82\nmov     rcx, rax                                                       ; +0x1b5, 0x140278a85\ncall    qword ptr [rdx+48h]                                            ; +0x1b8, 0x140278a88\nmov     rax, cs:qword_1406C2ED8                                        ; +0x1bb, 0x140278a8b\nmov     qword ptr [rax+3A0h], 0                                        ; +0x1c2, 0x140278a92\ncmp     byte ptr [rax+2A5h], 0                                         ; +0x1cd, 0x140278a9d\njz      short loc_140278B00                                            ; +0x1d4, 0x140278aa4\nmov     rcx, [rbp+48h]                                                 ; +0x1d6, 0x140278aa6\ntest    rcx, rcx                                                       ; +0x1da, 0x140278aaa\njz      short loc_140278B00                                            ; +0x1dd, 0x140278aad\nmov     rax, [rcx]                                                     ; +0x1df, 0x140278aaf\nmov     dl, 1                                                          ; +0x1e2, 0x140278ab2\ncall    qword ptr [rax+230h]                                           ; +0x1e4, 0x140278ab4\nmov     rax, cs:qword_1406C2ED8                                        ; +0x1ea, 0x140278aba\ntest    rax, rax                                                       ; +0x1f1, 0x140278ac1\njnz     short loc_140278AF5                                            ; +0x1f4, 0x140278ac4\nmov     ecx, 668h; Size                                                ; +0x1f6, 0x140278ac6\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x1fb, 0x140278acb\nmov     [rsp+38h+arg_8], rax                                           ; +0x200, 0x140278ad0\nmov     rcx, rax                                                       ; +0x205, 0x140278ad5\ncall    sub_14017AB00                                                  ; +0x208, 0x140278ad8\nnop                                                                    ; +0x20d, 0x140278add\nmov     cs:qword_1406C2ED8, rax                                        ; +0x20e, 0x140278ade\nmov     rdx, [rax]                                                     ; +0x215, 0x140278ae5\nmov     rcx, rax                                                       ; +0x218, 0x140278ae8\ncall    qword ptr [rdx+48h]                                            ; +0x21b, 0x140278aeb\nmov     rax, cs:qword_1406C2ED8                                        ; +0x21e, 0x140278aee\nmov     qword ptr [rax+3A0h], 0                                        ; +0x225, 0x140278af5\nmov     rbx, [rsp+38h+arg_0]                                           ; +0x230, 0x140278b00\nadd     rsp, 20h                                                       ; +0x235, 0x140278b05\npop     rdi                                                            ; +0x239, 0x140278b09\npop     rsi                                                            ; +0x23a, 0x140278b0a\npop     rbp                                                            ; +0x23b, 0x140278b0b\nretn                                                                   ; +0x23c, 0x140278b0c", "xrefs": ["<???> @ 0x14056ad28", "<???> @ 0x1406d1004", "<???> @ 0x1406d1010"], "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"}