//
// GameObject::updateObjectEditorColor from 0x14029e1f0 to 0x14029e2a9 (185 bytes)
//
// 19 xrefs:
// > CustomizeObjectLayer::onLiveEdit @ 0x140142029
// > CustomizeObjectLayer::onLiveEdit @ 0x140142077
// > EditorUI::editColor @ 0x1401be25e
// > EditorUI::editColor @ 0x1401be2a9
// > EditorUI::editHSV @ 0x1401be44c
// > EditorUI::editHSV @ 0x1401be494
// > EditorUI::ccTouchEnded @ 0x1401c1808
// > EditorUI::ccTouchEnded @ 0x1401c1859
// > EditorUI::ccTouchEnded @ 0x1401c1908
// > EditorUI::deselectObject @ 0x1401c821b
// > EditorUI::deselectObject @ 0x1401c826a
// > EditorUI::deselectAll @ 0x1401c82db
// > EditorUI::deselectAll @ 0x1401c8349
// > EditorUI::deselectTargetPortals @ 0x1401c84be
// > EditorUI::deselectObjectsColor @ 0x1401c9861
// > EditorUI::deselectObjectsColor @ 0x1401c98a9
// > LevelEditorLayer::updateVisibility @ 0x1403f72dd
// > ParticleGameObject::updateParticle @ 0x1406426c1
// > ??> @ 0x14091d8b8
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:29:14 +0000
//
__int64 __fastcall GameObject::updateObjectEditorColor(_QWORD *a1)
{
int *v1; // rax
int v3; // r8d
__int64 v4; // rax
__int64 result; // rax
int *v6; // rax
int v7; // r8d
char v8; // [rsp+30h] [rbp+8h] BYREF
v1 = (int *)a1[138];
v3 = *v1;
if ( v1[1] == *v1 || !v3 )
v3 = 0;
v4 = GameObject::editorColorForMode((__int64)a1, (__int64)&v8, v3);
result = (*(__int64 (__fastcall **)(_QWORD *, __int64))(*a1 + 1344LL))(a1, v4);
if ( a1[112] )
{
v6 = (int *)a1[139];
v7 = *v6;
if ( v6[1] == *v6 || !v7 )
v7 = 0;
GameObject::editorColorForMode((__int64)a1, (__int64)&v8, v7);
result = (*(__int64 (__fastcall **)(_QWORD *, char *))(*a1 + 1440LL))(a1, &v8);
}
if ( *((_BYTE *)a1 + 772) )
{
result = (*(__int64 (__fastcall **)(_QWORD *, __int64))(*a1 + 472LL))(a1, 999);
if ( result )
return (**(__int64 (__fastcall ***)(__int64, __int16 *))(result + 368))(result + 368, &word_14070341C);
}
return result;
}