//
// GJGroundLayer::updateGround01Color from 0x1006be420 to 0x1006be495 (117 bytes)
//
// 11 xrefs:
// > LevelEditorLayer::updateEditorMode @ 0x1000ada20
// > LevelEditorLayer::updateEditorMode @ 0x1000ada9a
// > GJBaseGameLayer::updateLevelColors @ 0x1000f08fa
// > GJBaseGameLayer::updateLevelColors @ 0x1000f0909
// > GJBaseGameLayer::visitWithColorFlash @ 0x1001445da
// > GJBaseGameLayer::visitWithColorFlash @ 0x1001445e9
// > GJBaseGameLayer::visitWithColorFlash @ 0x10014463c
// > GJBaseGameLayer::visitWithColorFlash @ 0x100144655
// > LevelSelectLayer::scrollLayerMoved @ 0x100421d54
// > MenuGameLayer::updateColors @ 0x1004f9a20
// > MenuGameLayer::update @ 0x1004f9ad6
//
// 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 12:35:30 +0000
//
__int64 __fastcall GJGroundLayer::updateGround01Color(__int64 a1, int a2)
{
__int64 v2; // rax
__int64 result; // rax
__int64 v4; // rbx
unsigned int v5; // r14d
__int64 v6; // rax
__int16 v7; // [rsp+0h] [rbp-1Ch] BYREF
char v8; // [rsp+2h] [rbp-1Ah]
char v9; // [rsp+3h] [rbp-19h]
v9 = HIBYTE(v2);
v7 = a2;
v8 = BYTE2(a2);
result = (*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 408) + 488LL))(*(_QWORD *)(a1 + 408));
if ( result )
{
v4 = result;
result = sub_1007FEF90(result);
if ( (_DWORD)result )
{
v5 = 0;
do
{
v6 = sub_1007FEFE0(v4, v5);
(*(void (__fastcall **)(__int64, __int16 *))(*(_QWORD *)v6 + 960LL))(v6, &v7);
++v5;
result = sub_1007FEF90(v4);
}
while ( v5 < (unsigned int)result );
}
}
return result;
}