//
// EditorUI::disableButton from 0x1003e7064 to 0x1003e7170 (268 bytes)
//
// 1 xrefs:
// > EditorUI::updateCreateMenu @ 0x1003e6dc0
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void __fastcall EditorUI::disableButton(EditorUI *a1, CreateMenuItem *a2)
{
_QWORD *v3; // x20
__int64 v4; // x0
void (*v5)(void); // x8
__int64 v6; // x0
__int64 v7; // x19
__int16 v8; // [xsp+0h] [xbp-30h] BYREF
char v9; // [xsp+2h] [xbp-2Eh]
__int16 v10; // [xsp+4h] [xbp-2Ch] BYREF
char v11; // [xsp+6h] [xbp-2Ah]
__int16 v12; // [xsp+8h] [xbp-28h]
char v13; // [xsp+Ah] [xbp-26h]
__int16 v14; // [xsp+Ch] [xbp-24h]
char v15; // [xsp+Eh] [xbp-22h]
v3 = (_QWORD *)((__int64 (__fastcall *)(CreateMenuItem *))a2->getNormalImage)(a2);
v4 = v3[80];
if ( v4 )
{
v14 = 32639;
v15 = 127;
v5 = *(void (**)(void))(*(_QWORD *)v4 + 944LL);
}
else
{
v6 = v3[81];
if ( !v6 )
goto LABEL_6;
v12 = 32639;
v13 = 127;
v5 = *(void (**)(void))(*(_QWORD *)v6 + 944LL);
}
v5();
LABEL_6:
if ( (a2->m_objectID & 0x80000000) == 0 )
{
v7 = v3[79];
v11 = 127;
v10 = 32639;
v9 = 127;
v8 = 25700;
if ( *(_DWORD *)(v7 + 1248) == 1 && GameObject::isColorObject((GameObject *)v7) && *(_BYTE *)(v7 + 1768) == 1 )
{
v10 = v8;
v11 = v9;
}
(*(void (__fastcall **)(__int64, __int16 *))(*(_QWORD *)v7 + 1480LL))(v7, &v10);
(*(void (__fastcall **)(__int64, __int16 *))(*(_QWORD *)v7 + 1080LL))(v7, &v8);
}
}