//
// LevelEditorLayer::pasteColorState from 0x100405c78 to 0x100405d0c (148 bytes)
//
// 2 xrefs:
// > CustomizeObjectLayer::onPaste @ 0x10005881c
// > EditorUI::onPasteColor @ 0x10018b030
//
// This function is hookable on this platform (idp: arm, 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:04:41 +0000
//
void __fastcall LevelEditorLayer::pasteColorState(__int64 a1, __int64 a2, __int64 a3)
{
__int64 v4; // x1
unsigned int *v5; // x9
__int64 v6; // x8
__int64 *v8; // x21
unsigned __int64 v9; // x22
__int64 v10; // x20
v4 = *(_QWORD *)(a1 + 14120);
if ( v4 )
{
if ( a2 )
{
GameObject::duplicateColorMode(a2, v4);
*(_BYTE *)(a2 + 1148) = 1;
}
else if ( a3 )
{
v5 = *(unsigned int **)(a3 + 56);
v6 = *v5;
if ( (_DWORD)v6 )
{
v8 = *((__int64 **)v5 + 2);
v9 = (unsigned __int64)&v8[v6 - 1];
do
{
v10 = *v8;
if ( !*v8 )
break;
GameObject::duplicateColorMode(*v8, *(_QWORD *)(a1 + 14120));
*(_BYTE *)(v10 + 1148) = 1;
++v8;
}
while ( (unsigned __int64)v8 <= v9 );
}
}
}
}