{"type": "func", "start": 6038140, "end": 6038406, "name": "ColorChannelSprite::updateOpacity", "pseudocode": "// \n// ColorChannelSprite::updateOpacity from 0x5c227c to 0x5c2386 (266 bytes)\n// \n// 2 xrefs:\n// > ColorChannelSprite::updateValues @ 0x5c2492\n// > ColorChannelSprite::updateValues @ 0x5c24ee\n// \n// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\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 11:53:50 +0000\n// \n\nint __fastcall ColorChannelSprite::updateOpacity(int this, const char *a2)\n{\n  _DWORD *v2; // r4\n  int v4; // r3\n  int v5; // r0\n  int v6; // r3\n  int v7; // r7\n  void (__fastcall *v8)(int, _BYTE *); // r8\n  float v9; // s18\n  int v10; // r0\n  int *v11; // r5\n  int v12; // r3\n  void (__fastcall *v13)(int *, int); // r7\n  cocos2d::CCString *v14; // r0\n  int CString; // r0\n  _BYTE v16[8]; // [sp+4h] [bp-Ch] BYREF\n\n  v2 = (_DWORD *)this;\n  v4 = *(_DWORD *)(this + 512);\n  if ( *(float *)&a2 != 1.0 || v4 )\n  {\n    if ( !v4 )\n    {\n      v5 = cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)\" \", \"bigFont.fnt\", _stack_chk_guard);\n      v6 = *v2;\n      v2[128] = v5;\n      (*(void (__fastcall **)(_DWORD *, int))(v6 + 228))(v2, v5);\n      v7 = v2[128];\n      v8 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v7 + 92);\n      v9 = *(float *)(*(int (__fastcall **)(_DWORD *))(*v2 + 164))(v2);\n      v10 = (*(int (__fastcall **)(_DWORD *))(*v2 + 164))(v2);\n      cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, v9 * 0.5, (float)(*(float *)(v10 + 4) * 0.5) - 9.5);\n      v8(v7, v16);\n      (*(void (__fastcall **)(_DWORD, int))(*(_DWORD *)v2[128] + 80))(v2[128], 1050253722);\n    }\n    v11 = (int *)v2[128];\n    v12 = *v11;\n    if ( *(float *)&a2 == 1.0 )\n    {\n      return (*(int (__fastcall **)(_DWORD, _DWORD))(v12 + 172))(v2[128], 0);\n    }\n    else\n    {\n      v13 = *(void (__fastcall **)(int *, int))(v12 + 464);\n      v14 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)\"%0.2f\", a2, *(float *)&a2);\n      CString = cocos2d::CCString::getCString(v14);\n      v13(v11, CString);\n      return (*(int (__fastcall **)(_DWORD, int))(*(_DWORD *)v2[128] + 172))(v2[128], 1);\n    }\n  }\n  return this;\n}", "assembly": "; \n; ColorChannelSprite::updateOpacity from 0x5c227c to 0x5c2386 (266 bytes)\n; \n; 2 xrefs:\n; > ColorChannelSprite::updateValues @ 0x5c2492\n; > ColorChannelSprite::updateValues @ 0x5c24ee\n; \n; This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\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 11:53:50 +0000\n; \nVMOV.F32        S15, #1.0                                              ; +0x0, 0x5c227c\nLDR             R3, =(__stack_chk_guard_ptr - 0x5C228A)                ; +0x4, 0x5c2280\nPUSH.W          {R4-R8,LR}                                             ; +0x6, 0x5c2282\nADD             R3, PC; __stack_chk_guard_ptr                          ; +0xa, 0x5c2286\nLDR             R3, [R3]; __stack_chk_guard                            ; +0xc, 0x5c2288\nVPUSH           {D8-D9}                                                ; +0xe, 0x5c228a\nMOV             R4, R0                                                 ; +0x12, 0x5c228e\nMOV             R6, R3                                                 ; +0x14, 0x5c2290\nVMOV            S17, R1                                                ; +0x16, 0x5c2292\nLDR             R2, [R3]; char *                                       ; +0x1a, 0x5c2296\nSUB             SP, SP, #0x10                                          ; +0x1c, 0x5c2298\nLDR.W           R3, [R0,#0x200]                                        ; +0x1e, 0x5c229a\nVCMP.F32        S17, S15                                               ; +0x22, 0x5c229e\nSTR             R2, [SP,#0x10+var_4]                                   ; +0x26, 0x5c22a2\nVMRS            APSR_nzcv, FPSCR                                       ; +0x28, 0x5c22a4\nVMOV.F32        S16, S15                                               ; +0x2c, 0x5c22a8\nBNE             loc_5C22B2                                             ; +0x30, 0x5c22ac\nCMP             R3, #0                                                 ; +0x32, 0x5c22ae\nBEQ             loc_5C2370                                             ; +0x34, 0x5c22b0\nCMP             R3, #0                                                 ; +0x36, 0x5c22b2\nBNE             loc_5C232A                                             ; +0x38, 0x5c22b4\nLDR             R0, =(asc_B7533B - 0x5C22C4); \" \"                      ; +0x3a, 0x5c22b6\nVMOV.F32        S19, #0.5                                              ; +0x3c, 0x5c22b8\nLDR             R1, =(aBigfontFnt - 0x5C22C6); \"bigFont.fnt\"           ; +0x40, 0x5c22bc\nADD             R5, SP, #0x10+var_C                                    ; +0x42, 0x5c22be\nADD             R0, PC; \" \"                                            ; +0x44, 0x5c22c0\nADD             R1, PC; \"bigFont.fnt\"                                  ; +0x46, 0x5c22c2\nBL              _ZN7cocos2d13CCLabelBMFont6createEPKcS2_; cocos2d::CCLabelBMFont::create(char const*,char const*) ; +0x48, 0x5c22c4\nLDR             R3, [R4]                                               ; +0x4c, 0x5c22c8\nMOV             R1, R0                                                 ; +0x4e, 0x5c22ca\nSTR.W           R0, [R4,#0x200]                                        ; +0x50, 0x5c22cc\nMOV             R0, R4                                                 ; +0x54, 0x5c22d0\nLDR.W           R3, [R3,#0xE4]                                         ; +0x56, 0x5c22d2\nBLX             R3                                                     ; +0x5a, 0x5c22d6\nLDR.W           R7, [R4,#0x200]                                        ; +0x5c, 0x5c22d8\nMOV             R0, R4                                                 ; +0x60, 0x5c22dc\nLDR             R3, [R7]                                               ; +0x62, 0x5c22de\nLDR.W           R8, [R3,#0x5C]                                         ; +0x64, 0x5c22e0\nLDR             R3, [R4]                                               ; +0x68, 0x5c22e4\nLDR.W           R3, [R3,#0xA4]                                         ; +0x6a, 0x5c22e6\nBLX             R3                                                     ; +0x6e, 0x5c22ea\nLDR             R3, [R4]                                               ; +0x70, 0x5c22ec\nLDR.W           R3, [R3,#0xA4]                                         ; +0x72, 0x5c22ee\nVLDR            S18, [R0]                                              ; +0x76, 0x5c22f2\nMOV             R0, R4                                                 ; +0x7a, 0x5c22f6\nBLX             R3                                                     ; +0x7c, 0x5c22f8\nVMOV.F32        S15, #9.5                                              ; +0x7e, 0x5c22fa\nVMUL.F32        S18, S18, S19                                          ; +0x82, 0x5c22fe\nVMOV            R1, S18; float                                         ; +0x86, 0x5c2302\nVLDR            S14, [R0,#4]                                           ; +0x8a, 0x5c2306\nMOV             R0, R5; this                                           ; +0x8e, 0x5c230a\nVNMLS.F32       S15, S14, S19                                          ; +0x90, 0x5c230c\nVMOV            R2, S15; float                                         ; +0x94, 0x5c2310\nBL              _ZN7cocos2d7CCPointC1Eff; cocos2d::CCPoint::CCPoint(float,float) ; +0x98, 0x5c2314\nMOV             R0, R7                                                 ; +0x9c, 0x5c2318\nMOV             R1, R5                                                 ; +0x9e, 0x5c231a\nBLX             R8                                                     ; +0xa0, 0x5c231c\nLDR.W           R0, [R4,#0x200]                                        ; +0xa2, 0x5c231e\nLDR             R1, =0x3E99999A                                        ; +0xa6, 0x5c2322\nLDR             R3, [R0]                                               ; +0xa8, 0x5c2324\nLDR             R3, [R3,#0x50]                                         ; +0xaa, 0x5c2326\nBLX             R3                                                     ; +0xac, 0x5c2328\nVCMP.F32        S17, S16                                               ; +0xae, 0x5c232a\nLDR.W           R5, [R4,#0x200]                                        ; +0xb2, 0x5c232e\nLDR             R3, [R5]                                               ; +0xb6, 0x5c2332\nVMRS            APSR_nzcv, FPSCR                                       ; +0xb8, 0x5c2334\nBNE             loc_5C2344                                             ; +0xbc, 0x5c2338\nLDR.W           R3, [R3,#0xAC]                                         ; +0xbe, 0x5c233a\nMOV             R0, R5                                                 ; +0xc2, 0x5c233e\nMOVS            R1, #0                                                 ; +0xc4, 0x5c2340\nB               loc_5C236E                                             ; +0xc6, 0x5c2342\nVCVT.F64.F32    D7, S17                                                ; +0xc8, 0x5c2344\nLDR             R0, =(a02f - 0x5C2352); \"%0.2f\"                        ; +0xcc, 0x5c2348\nLDR.W           R7, [R3,#0x1D0]                                        ; +0xce, 0x5c234a\nADD             R0, PC; \"%0.2f\"                                        ; +0xd2, 0x5c234e\nVMOV            R2, R3, D7                                             ; +0xd4, 0x5c2350\nBL              _ZN7cocos2d8CCString16createWithFormatEPKcz; cocos2d::CCString::createWithFormat(char const*,...) ; +0xd8, 0x5c2354\nBL              _ZNK7cocos2d8CCString10getCStringEv; cocos2d::CCString::getCString(void) ; +0xdc, 0x5c2358\nMOV             R1, R0                                                 ; +0xe0, 0x5c235c\nMOV             R0, R5                                                 ; +0xe2, 0x5c235e\nBLX             R7                                                     ; +0xe4, 0x5c2360\nLDR.W           R0, [R4,#0x200]                                        ; +0xe6, 0x5c2362\nMOVS            R1, #1                                                 ; +0xea, 0x5c2366\nLDR             R3, [R0]                                               ; +0xec, 0x5c2368\nLDR.W           R3, [R3,#0xAC]                                         ; +0xee, 0x5c236a\nBLX             R3                                                     ; +0xf2, 0x5c236e\nLDR             R2, [SP,#0x10+var_4]                                   ; +0xf4, 0x5c2370\nLDR             R3, [R6]                                               ; +0xf6, 0x5c2372\nCMP             R2, R3                                                 ; +0xf8, 0x5c2374\nBEQ             loc_5C237C                                             ; +0xfa, 0x5c2376\nBLX             __stack_chk_fail                                       ; +0xfc, 0x5c2378\nADD             SP, SP, #0x10                                          ; +0x100, 0x5c237c\nVPOP            {D8-D9}                                                ; +0x102, 0x5c237e\nPOP.W           {R4-R8,PC}                                             ; +0x106, 0x5c2382", "xrefs": ["ColorChannelSprite::updateValues @ 0x5c2492", "ColorChannelSprite::updateValues @ 0x5c24ee"], "is_objc": false, "is_32_bit": true, "is_64_bit": false, "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"}