{"type": "func", "start": 6180212, "end": 6180564, "name": "ConfigureHSVWidget::setBaseColor", "pseudocode": "// \n// ConfigureHSVWidget::setBaseColor from 0x5e4d74 to 0x5e4ed4 (352 bytes)\n// \n// 2 xrefs:\n// > HSVWidgetPopup::init @ 0x5e6022\n// > HSVLiveOverlay::createHSVWidget @ 0x69c42c\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:54:19 +0000\n// \n\nint __fastcall ConfigureHSVWidget::setBaseColor(int a1, unsigned int a2)\n{\n  int v3; // r2\n  const char *v4; // r1\n  int v5; // r2\n  int v6; // r0\n  float v7; // s16\n  float v8; // s16\n  int v9; // r8\n  void (__fastcall *v10)(int, _BYTE *); // r9\n  const char *v11; // r1\n  int v12; // r0\n  int v13; // r7\n  void (__fastcall *v14)(int, _BYTE *); // r9\n  int v15; // r10\n  int v16; // r0\n  char v17; // r3\n  int v18; // r0\n  _BYTE v20[8]; // [sp+14h] [bp-14h] BYREF\n  _BYTE v21[8]; // [sp+1Ch] [bp-Ch] BYREF\n  int v22; // [sp+24h] [bp-4h]\n\n  v3 = _stack_chk_guard;\n  *(_WORD *)(a1 + 324) = a2;\n  v4 = (const char *)HIWORD(a2);\n  v22 = v3;\n  *(_BYTE *)(a1 + 336) = 1;\n  v5 = *(_DWORD *)(a1 + 332);\n  *(_BYTE *)(a1 + 326) = (_BYTE)v4;\n  if ( !v5 )\n  {\n    v6 = cocos2d::CCSprite::createWithSpriteFrameName((cocos2d::CCSprite *)\"whiteSquare60_001.png\", v4);\n    *(_DWORD *)(a1 + 332) = v6;\n    (*(void (__fastcall **)(int, int))(*(_DWORD *)v6 + 80))(v6, 1060320051);\n    v7 = *(float *)((*(int (__fastcall **)(_DWORD))(**(_DWORD **)(a1 + 332) + 164))(*(_DWORD *)(a1 + 332)) + 4);\n    v8 = v7 * COERCE_FLOAT((*(int (__fastcall **)(_DWORD))(**(_DWORD **)(a1 + 332) + 84))(*(_DWORD *)(a1 + 332)));\n    (*(void (__fastcall **)(int, _DWORD))(*(_DWORD *)a1 + 228))(a1, *(_DWORD *)(a1 + 332));\n    v9 = *(_DWORD *)(a1 + 332);\n    v10 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v9 + 92);\n    cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v21, 155.0, (float)((float)(v8 * 1.5) - 80.0) + 4.0);\n    v10(v9, v21);\n    v12 = cocos2d::CCSprite::createWithSpriteFrameName((cocos2d::CCSprite *)\"whiteSquare60_001.png\", v11);\n    *(_DWORD *)(a1 + 328) = v12;\n    (*(void (__fastcall **)(int, int))(*(_DWORD *)v12 + 80))(v12, 1060320051);\n    (*(void (__fastcall **)(int, _DWORD))(*(_DWORD *)a1 + 228))(a1, *(_DWORD *)(a1 + 328));\n    v13 = *(_DWORD *)(a1 + 328);\n    v14 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v13 + 92);\n    v15 = (*(int (__fastcall **)(_DWORD))(**(_DWORD **)(a1 + 332) + 96))(*(_DWORD *)(a1 + 332));\n    cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v20, 0.0, -v8);\n    cocos2d::CCPoint::operator+(v21, v15, v20);\n    v14(v13, v21);\n  }\n  v16 = GameToolbox::transformColor(\n          (unsigned __int8 *)(a1 + 324),\n          *(float *)(a1 + 292),\n          *(float *)(a1 + 296),\n          *(float *)(a1 + 300),\n          *(_DWORD *)(a1 + 304));\n  v17 = BYTE1(v16);\n  v21[0] = v16;\n  v21[2] = BYTE2(v16);\n  v18 = *(_DWORD *)(a1 + 328);\n  v21[1] = v17;\n  (*(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v18 + 480))(v18, v21);\n  return (*(int (__fastcall **)(_DWORD, _BYTE *))(**(_DWORD **)(a1 + 332) + 480))(*(_DWORD *)(a1 + 332), v21);\n}", "assembly": "; \n; ConfigureHSVWidget::setBaseColor from 0x5e4d74 to 0x5e4ed4 (352 bytes)\n; \n; 2 xrefs:\n; > HSVWidgetPopup::init @ 0x5e6022\n; > HSVLiveOverlay::createHSVWidget @ 0x69c42c\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:54:19 +0000\n; \nPUSH.W          {R4-R10,LR}                                            ; +0x0, 0x5e4d74\nMOV             R4, R0                                                 ; +0x4, 0x5e4d78\nVPUSH           {D8}                                                   ; +0x6, 0x5e4d7a\nLDR             R3, =(__stack_chk_guard_ptr - 0x5E4D84)                ; +0xa, 0x5e4d7e\nADD             R3, PC; __stack_chk_guard_ptr                          ; +0xc, 0x5e4d80\nLDR             R3, [R3]; __stack_chk_guard                            ; +0xe, 0x5e4d82\nSUB             SP, SP, #0x28                                          ; +0x10, 0x5e4d84\nLDR             R2, [R3]                                               ; +0x12, 0x5e4d86\nMOV             R5, R3                                                 ; +0x14, 0x5e4d88\nSTR             R1, [SP,#0x28+var_1C]                                  ; +0x16, 0x5e4d8a\nADD             R6, SP, #0x28+var_C                                    ; +0x18, 0x5e4d8c\nSTRH.W          R1, [R0,#0x144]                                        ; +0x1a, 0x5e4d8e\nLSRS            R1, R1, #0x10; char *                                  ; +0x1e, 0x5e4d92\nSTR             R2, [SP,#0x28+var_4]                                   ; +0x20, 0x5e4d94\nMOVS            R2, #1                                                 ; +0x22, 0x5e4d96\nSTRB.W          R2, [R0,#0x150]                                        ; +0x24, 0x5e4d98\nLDR.W           R2, [R0,#0x14C]                                        ; +0x28, 0x5e4d9c\nSTRB.W          R1, [R0,#0x146]                                        ; +0x2c, 0x5e4da0\nCMP             R2, #0                                                 ; +0x30, 0x5e4da4\nBNE             loc_5E4E7A                                             ; +0x32, 0x5e4da6\nLDR             R7, =(aWhitesquare600 - 0x5E4DAE); \"whiteSquare60_001.png\" ; +0x34, 0x5e4da8\nADD             R7, PC; \"whiteSquare60_001.png\"                        ; +0x36, 0x5e4daa\nMOV             R0, R7; this                                           ; +0x38, 0x5e4dac\nBL              _ZN7cocos2d8CCSprite25createWithSpriteFrameNameEPKc; cocos2d::CCSprite::createWithSpriteFrameName(char const*) ; +0x3a, 0x5e4dae\nLDR             R1, =0x3F333333                                        ; +0x3e, 0x5e4db2\nSTR.W           R0, [R4,#0x14C]                                        ; +0x40, 0x5e4db4\nLDR             R3, [R0]                                               ; +0x44, 0x5e4db8\nLDR             R3, [R3,#0x50]                                         ; +0x46, 0x5e4dba\nBLX             R3                                                     ; +0x48, 0x5e4dbc\nLDR.W           R0, [R4,#0x14C]                                        ; +0x4a, 0x5e4dbe\nLDR             R3, [R0]                                               ; +0x4e, 0x5e4dc2\nLDR.W           R3, [R3,#0xA4]                                         ; +0x50, 0x5e4dc4\nBLX             R3                                                     ; +0x54, 0x5e4dc8\nVLDR            S16, [R0,#4]                                           ; +0x56, 0x5e4dca\nLDR.W           R0, [R4,#0x14C]                                        ; +0x5a, 0x5e4dce\nLDR             R3, [R0]                                               ; +0x5e, 0x5e4dd2\nLDR             R3, [R3,#0x54]                                         ; +0x60, 0x5e4dd4\nBLX             R3                                                     ; +0x62, 0x5e4dd6\nLDR             R3, [R4]                                               ; +0x64, 0x5e4dd8\nLDR.W           R1, [R4,#0x14C]                                        ; +0x66, 0x5e4dda\nLDR.W           R3, [R3,#0xE4]                                         ; +0x6a, 0x5e4dde\nVMOV            S15, R0                                                ; +0x6e, 0x5e4de2\nMOV             R0, R4                                                 ; +0x72, 0x5e4de6\nVMUL.F32        S16, S16, S15                                          ; +0x74, 0x5e4de8\nBLX             R3                                                     ; +0x78, 0x5e4dec\nVLDR            S15, =80.0                                             ; +0x7a, 0x5e4dee\nMOV             R0, R6; this                                           ; +0x7e, 0x5e4df2\nLDR.W           R8, [R4,#0x14C]                                        ; +0x80, 0x5e4df4\nLDR             R1, flt_5E4EDC; float                                  ; +0x84, 0x5e4df8\nLDR.W           R3, [R8]                                               ; +0x86, 0x5e4dfa\nLDR.W           R9, [R3,#0x5C]                                         ; +0x8a, 0x5e4dfe\nVMOV.F32        S14, #1.5                                              ; +0x8e, 0x5e4e02\nVNMLS.F32       S15, S16, S14                                          ; +0x92, 0x5e4e06\nVMOV.F32        S14, #4.0                                              ; +0x96, 0x5e4e0a\nVADD.F32        S15, S15, S14                                          ; +0x9a, 0x5e4e0e\nVMOV            R2, S15; float                                         ; +0x9e, 0x5e4e12\nBL              _ZN7cocos2d7CCPointC1Eff; cocos2d::CCPoint::CCPoint(float,float) ; +0xa2, 0x5e4e16\nMOV             R0, R8                                                 ; +0xa6, 0x5e4e1a\nMOV             R1, R6                                                 ; +0xa8, 0x5e4e1c\nADD.W           R8, SP, #0x28+var_14                                   ; +0xaa, 0x5e4e1e\nBLX             R9                                                     ; +0xae, 0x5e4e22\nMOV             R0, R7; this                                           ; +0xb0, 0x5e4e24\nBL              _ZN7cocos2d8CCSprite25createWithSpriteFrameNameEPKc; cocos2d::CCSprite::createWithSpriteFrameName(char const*) ; +0xb2, 0x5e4e26\nLDR             R1, =0x3F333333                                        ; +0xb6, 0x5e4e2a\nSTR.W           R0, [R4,#0x148]                                        ; +0xb8, 0x5e4e2c\nLDR             R3, [R0]                                               ; +0xbc, 0x5e4e30\nLDR             R3, [R3,#0x50]                                         ; +0xbe, 0x5e4e32\nBLX             R3                                                     ; +0xc0, 0x5e4e34\nLDR             R3, [R4]                                               ; +0xc2, 0x5e4e36\nLDR.W           R1, [R4,#0x148]                                        ; +0xc4, 0x5e4e38\nMOV             R0, R4                                                 ; +0xc8, 0x5e4e3c\nLDR.W           R3, [R3,#0xE4]                                         ; +0xca, 0x5e4e3e\nBLX             R3                                                     ; +0xce, 0x5e4e42\nLDR.W           R7, [R4,#0x148]                                        ; +0xd0, 0x5e4e44\nLDR.W           R0, [R4,#0x14C]                                        ; +0xd4, 0x5e4e48\nLDR             R3, [R7]                                               ; +0xd8, 0x5e4e4c\nLDR.W           R9, [R3,#0x5C]                                         ; +0xda, 0x5e4e4e\nLDR             R3, [R0]                                               ; +0xde, 0x5e4e52\nLDR             R3, [R3,#0x60]                                         ; +0xe0, 0x5e4e54\nBLX             R3                                                     ; +0xe2, 0x5e4e56\nVNEG.F32        S15, S16                                               ; +0xe4, 0x5e4e58\nMOVS            R1, #0; float                                          ; +0xe8, 0x5e4e5c\nVMOV            R2, S15; float                                         ; +0xea, 0x5e4e5e\nMOV             R10, R0                                                ; +0xee, 0x5e4e62\nMOV             R0, R8; this                                           ; +0xf0, 0x5e4e64\nBL              _ZN7cocos2d7CCPointC1Eff; cocos2d::CCPoint::CCPoint(float,float) ; +0xf2, 0x5e4e66\nMOV             R0, R6                                                 ; +0xf6, 0x5e4e6a\nMOV             R1, R10                                                ; +0xf8, 0x5e4e6c\nMOV             R2, R8                                                 ; +0xfa, 0x5e4e6e\nBL              _ZNK7cocos2d7CCPointplERKS0_; cocos2d::CCPoint::operator+(cocos2d::CCPoint const&) ; +0xfc, 0x5e4e70\nMOV             R0, R7                                                 ; +0x100, 0x5e4e74\nMOV             R1, R6                                                 ; +0x102, 0x5e4e76\nBLX             R9                                                     ; +0x104, 0x5e4e78\nLDR.W           R3, [R4,#0x130]                                        ; +0x106, 0x5e4e7a\nADD.W           R0, R4, #0x144                                         ; +0x10a, 0x5e4e7e\nSTR             R3, [SP,#0x28+var_28]                                  ; +0x10e, 0x5e4e82\nADD.W           R3, R4, #0x124                                         ; +0x110, 0x5e4e84\nLDM             R3, {R1-R3}                                            ; +0x114, 0x5e4e88\nBL              _ZN11GameToolbox14transformColorERKN7cocos2d10_ccColor3BENS0_11_ccHSVValueE; GameToolbox::transformColor(cocos2d::_ccColor3B const&,cocos2d::_ccHSVValue) ; +0x116, 0x5e4e8a\nMOV             R1, R6                                                 ; +0x11a, 0x5e4e8e\nSTRB.W          R0, [SP,#0x28+var_C]                                   ; +0x11c, 0x5e4e90\nUBFX.W          R3, R0, #8, #8                                         ; +0x120, 0x5e4e94\nUBFX.W          R0, R0, #0x10, #8                                      ; +0x124, 0x5e4e98\nSTRB.W          R0, [SP,#0x28+var_A]                                   ; +0x128, 0x5e4e9c\nLDR.W           R0, [R4,#0x148]                                        ; +0x12c, 0x5e4ea0\nSTRB.W          R3, [SP,#0x28+var_B]                                   ; +0x130, 0x5e4ea4\nLDR             R3, [R0]                                               ; +0x134, 0x5e4ea8\nLDR.W           R3, [R3,#0x1E0]                                        ; +0x136, 0x5e4eaa\nBLX             R3                                                     ; +0x13a, 0x5e4eae\nLDR.W           R0, [R4,#0x14C]                                        ; +0x13c, 0x5e4eb0\nMOV             R1, R6                                                 ; +0x140, 0x5e4eb4\nLDR             R3, [R0]                                               ; +0x142, 0x5e4eb6\nLDR.W           R3, [R3,#0x1E0]                                        ; +0x144, 0x5e4eb8\nBLX             R3                                                     ; +0x148, 0x5e4ebc\nLDR             R2, [SP,#0x28+var_4]                                   ; +0x14a, 0x5e4ebe\nLDR             R3, [R5]                                               ; +0x14c, 0x5e4ec0\nCMP             R2, R3                                                 ; +0x14e, 0x5e4ec2\nBEQ             loc_5E4ECA                                             ; +0x150, 0x5e4ec4\nBLX             __stack_chk_fail                                       ; +0x152, 0x5e4ec6\nADD             SP, SP, #0x28 ; '('                                    ; +0x156, 0x5e4eca\nVPOP            {D8}                                                   ; +0x158, 0x5e4ecc\nPOP.W           {R4-R10,PC}                                            ; +0x15c, 0x5e4ed0", "xrefs": ["HSVWidgetPopup::init @ 0x5e6022", "HSVLiveOverlay::createHSVWidget @ 0x69c42c"], "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"}